Class TransitionDAO

  • All Implemented Interfaces:
    ITransitionDAO

    public final class TransitionDAO
    extends Object
    implements ITransitionDAO
    This class provides Data Access methods for Transition objects
    • Constructor Summary

      Constructors 
      Constructor Description
      TransitionDAO()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void delete​(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Delete a record from the table
      void deleteByStep​(int nIdStep, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Remove all the transitions starting from or leading to a given step
      Transition getTransitionByPriority​(int nIdStep, int nPriority, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the data of a transition object from the given step and the given priority
      void insert​(Transition transition, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Insert a new record in the table.
      Transition load​(int nKey, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the data from the table
      List<Integer> selectIdTransitionsList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the id of all the transition objects and returns them as a list
      int selectMaxPriorityByStep​(int nIdStep, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Return the maximum priority value of the transitions from the given starting step
      List<Transition> selectTransitionsList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the data of all the transition objects and returns them as a list
      List<Transition> selectTransitionsListFromForm​(int nIdForm, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Select the transitions list from given form
      List<Transition> selectTransitionsListFromStep​(int nIdStep, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the data of all the transition objects from given step and returns them as a list
      fr.paris.lutece.util.ReferenceList selectTransitionsReferenceList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Load the data of all the transition objects and returns them as a referenceList
      void store​(Transition transition, fr.paris.lutece.portal.service.plugin.Plugin plugin)
      Update the record in the table
    • Constructor Detail

      • TransitionDAO

        public TransitionDAO()
    • Method Detail

      • insert

        public void insert​(Transition transition,
                           fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Insert a new record in the table.
        Specified by:
        insert in interface ITransitionDAO
        Parameters:
        transition - instance of the Transition object to insert
        plugin - the Plugin
      • load

        public Transition load​(int nKey,
                               fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the data from the table
        Specified by:
        load in interface ITransitionDAO
        Parameters:
        nKey - The identifier of the transition
        plugin - the Plugin
        Returns:
        The instance of the transition
      • selectMaxPriorityByStep

        public int selectMaxPriorityByStep​(int nIdStep,
                                           fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Return the maximum priority value of the transitions from the given starting step
        Specified by:
        selectMaxPriorityByStep in interface ITransitionDAO
        Parameters:
        nIdStep - The identifier of the step
        plugin - The Plugin
        Returns:
        the Transition object if existing
      • delete

        public void delete​(int nKey,
                           fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Delete a record from the table
        Specified by:
        delete in interface ITransitionDAO
        Parameters:
        nKey - The identifier of the Transition to delete
        plugin - the Plugin
      • store

        public void store​(Transition transition,
                          fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Update the record in the table
        Specified by:
        store in interface ITransitionDAO
        Parameters:
        transition - the reference of the Transition
        plugin - the Plugin
      • selectTransitionsList

        public List<Transition> selectTransitionsList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the data of all the transition objects and returns them as a list
        Specified by:
        selectTransitionsList in interface ITransitionDAO
        Parameters:
        plugin - the Plugin
        Returns:
        The list which contains the data of all the transition objects
      • selectIdTransitionsList

        public List<Integer> selectIdTransitionsList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the id of all the transition objects and returns them as a list
        Specified by:
        selectIdTransitionsList in interface ITransitionDAO
        Parameters:
        plugin - the Plugin
        Returns:
        The list which contains the id of all the transition objects
      • selectTransitionsReferenceList

        public fr.paris.lutece.util.ReferenceList selectTransitionsReferenceList​(fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the data of all the transition objects and returns them as a referenceList
        Specified by:
        selectTransitionsReferenceList in interface ITransitionDAO
        Parameters:
        plugin - the Plugin
        Returns:
        The referenceList which contains the data of all the transition objects
      • selectTransitionsListFromStep

        public List<Transition> selectTransitionsListFromStep​(int nIdStep,
                                                              fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the data of all the transition objects from given step and returns them as a list
        Specified by:
        selectTransitionsListFromStep in interface ITransitionDAO
        Parameters:
        nIdStep - The identifier of the starting step
        plugin - the Plugin
        Returns:
        The list which contains the data of all the transition objects
      • getTransitionByPriority

        public Transition getTransitionByPriority​(int nIdStep,
                                                  int nPriority,
                                                  fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Load the data of a transition object from the given step and the given priority
        Specified by:
        getTransitionByPriority in interface ITransitionDAO
        Parameters:
        nIdStep - The identifier of the step
        nPriority - The priority value
        plugin - The Plugin
        Returns:
        the Transition object if existing
      • deleteByStep

        public void deleteByStep​(int nIdStep,
                                 fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Remove all the transitions starting from or leading to a given step
        Specified by:
        deleteByStep in interface ITransitionDAO
        Parameters:
        nIdStep - The Step Id
        plugin - The Plugin
      • selectTransitionsListFromForm

        public List<Transition> selectTransitionsListFromForm​(int nIdForm,
                                                              fr.paris.lutece.portal.service.plugin.Plugin plugin)
        Select the transitions list from given form
        Specified by:
        selectTransitionsListFromForm in interface ITransitionDAO
        Parameters:
        nIdForm - The Form id
        plugin - The plugin
        Returns:
        the transitions list from given form id