Class TransitionHome
- java.lang.Object
-
- fr.paris.lutece.plugins.forms.business.TransitionHome
-
public final class TransitionHome extends Object
This class provides instances management methods (create, find, ...) for Transition objects
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Transitioncreate(Transition transition)Create an instance of the transition classstatic TransitioncreateWithoutPriorityCalculation(Transition transition)Create an instance of the transition classstatic TransitionfindByPrimaryKey(int nKey)Returns an instance of a transition whose identifier is specified in parameterstatic intgetCurrentPriorityByStep(int fromStep)Select the lowest priority of the transitions sharing the same starting Step Priority increase when value decrease.static List<Integer>getIdTransitionsList()Load the id of all the transition objects and returns them as a liststatic TransitiongetTransitionByPriority(int nIdStep, int nPriority)Load the data of a transition object from the given step and the given prioritystatic List<Transition>getTransitionsList()Load the data of all the transition objects and returns them as a liststatic List<Transition>getTransitionsListFromForm(int nIdForm)Load the data of all the transition objects from the given form and returns them as a liststatic List<Transition>getTransitionsListFromStep(int nIdStep)Load the data of all the transition objects from the given step and returns them as a liststatic fr.paris.lutece.util.ReferenceListgetTransitionsReferenceList()Load the data of all the transition objects and returns them as a referenceListstatic voidrebuildPrioritySequence(int fromStep)Rebuild the priority sequence of the transitions sharing the same starting Stepstatic voidremove(int nKey)Remove the transition whose identifier is specified in parameterstatic voidremoveTransitionByStep(int nIdStep)Remove all the transitions starting from or leading to a given stepstatic Transitionupdate(Transition transition)Update of the transition which is specified in parameter
-
-
-
Method Detail
-
create
public static Transition create(Transition transition)
Create an instance of the transition class- Parameters:
transition- The instance of the Transition which contains the informations to store- Returns:
- The instance of transition which has been created with its primary key.
-
createWithoutPriorityCalculation
public static Transition createWithoutPriorityCalculation(Transition transition)
Create an instance of the transition class- Parameters:
transition- The instance of the Transition which contains the informations to store- Returns:
- The instance of transition which has been created with its primary key.
-
update
public static Transition update(Transition transition)
Update of the transition which is specified in parameter- Parameters:
transition- The instance of the Transition which contains the data to store- Returns:
- The instance of the transition which has been updated
-
remove
public static void remove(int nKey)
Remove the transition whose identifier is specified in parameter- Parameters:
nKey- The transition Id
-
findByPrimaryKey
public static Transition findByPrimaryKey(int nKey)
Returns an instance of a transition whose identifier is specified in parameter- Parameters:
nKey- The transition primary key- Returns:
- an instance of Transition
-
getTransitionsList
public static List<Transition> getTransitionsList()
Load the data of all the transition objects and returns them as a list- Returns:
- the list which contains the data of all the transition objects
-
getIdTransitionsList
public static List<Integer> getIdTransitionsList()
Load the id of all the transition objects and returns them as a list- Returns:
- the list which contains the id of all the transition objects
-
getTransitionsReferenceList
public static fr.paris.lutece.util.ReferenceList getTransitionsReferenceList()
Load the data of all the transition objects and returns them as a referenceList- Returns:
- the referenceList which contains the data of all the transition objects
-
getTransitionsListFromStep
public static List<Transition> getTransitionsListFromStep(int nIdStep)
Load the data of all the transition objects from the given step and returns them as a list- Parameters:
nIdStep- The identifier of the starting step- Returns:
- the list which contains the data of all the transition objects
-
getTransitionByPriority
public static Transition getTransitionByPriority(int nIdStep, int nPriority)
Load the data of a transition object from the given step and the given priority- Parameters:
nIdStep- The identifier of the stepnPriority- The priority value- Returns:
- the transition object if existing
-
rebuildPrioritySequence
public static void rebuildPrioritySequence(int fromStep)
Rebuild the priority sequence of the transitions sharing the same starting Step- Parameters:
fromStep- The starting step
-
getCurrentPriorityByStep
public static int getCurrentPriorityByStep(int fromStep)
Select the lowest priority of the transitions sharing the same starting Step Priority increase when value decrease.- Parameters:
fromStep- The starting step- Returns:
- the Minimum priority ( maximum value )
-
removeTransitionByStep
public static void removeTransitionByStep(int nIdStep)
Remove all the transitions starting from or leading to a given step- Parameters:
nIdStep- The Step Id
-
getTransitionsListFromForm
public static List<Transition> getTransitionsListFromForm(int nIdForm)
Load the data of all the transition objects from the given form and returns them as a list- Parameters:
nIdForm-- Returns:
- the list which contains the data of all the transition objects for given form
-
-