Class FormHome
java.lang.Object
fr.paris.lutece.plugins.forms.business.FormHome
This class provides instances management methods (create, find, ...) for Form objects
-
Method Summary
Modifier and TypeMethodDescriptionstatic FormCreate an instance of the form classstatic FormfindByPrimaryKey(int nKey) Returns an instance of a form whose identifier is specified in parametergetFormByPrimaryKeyList(List<Integer> listIdForm) Load the data of all form Objects for a given list of form identifiersLoad the data of all the form objects and returns them as a listgetFormListSorted(FormItemSortConfig sortConfig) Load the data of all the form objects and returns them as a liststatic fr.paris.lutece.util.ReferenceListLoad the data of all the form objects and returns them as a referenceListstatic intgetNumberOfResponseFormByUser(int nIdForm, String strGuid) count the number of response for formstatic intgetNumberOfResponseForms(int nIdFormm) count the number of response for a formstatic voidremove(int nKey) Remove the form whose identifier is specified in parameterstatic FormUpdate of the form which is specified in parameter
-
Method Details
-
create
Create an instance of the form class- Parameters:
form- The instance of the Form which contains the informations to store- Returns:
- The instance of form which has been created with its primary key.
-
update
Update of the form which is specified in parameter- Parameters:
form- The instance of the Form which contains the data to store- Returns:
- The instance of the form which has been updated
-
remove
public static void remove(int nKey) Remove the form whose identifier is specified in parameter- Parameters:
nKey- The form Id
-
findByPrimaryKey
Returns an instance of a form whose identifier is specified in parameter- Parameters:
nKey- The form primary key- Returns:
- an instance of Form
-
getFormList
Load the data of all the form objects and returns them as a list- Returns:
- the list which contains the data of all the form objects
-
getFormListSorted
Load the data of all the form objects and returns them as a list- Returns:
- the list which contains the data of all the form objects
-
getFormsReferenceList
public static fr.paris.lutece.util.ReferenceList getFormsReferenceList()Load the data of all the form objects and returns them as a referenceList- Returns:
- the referenceList which contains the data of all the form objects
-
getNumberOfResponseForms
public static int getNumberOfResponseForms(int nIdFormm) count the number of response for a form- Parameters:
nIdFormm-- Returns:
- the number of response for a form
-
getNumberOfResponseFormByUser
count the number of response for form- Parameters:
nIdForm- id of formstrGuid- the name of user- Returns:
- the number of response for form corresponding of user
-
getFormByPrimaryKeyList
Load the data of all form Objects for a given list of form identifiers- Parameters:
listIdForm- The list of form identifiers- Returns:
- the form objects
-