Class UnitAssignmentDAO
java.lang.Object
fr.paris.lutece.plugins.unittree.business.assignment.UnitAssignmentDAO
- All Implemented Interfaces:
IUnitAssignmentDAO
This class provides Data Access methods for UnitAssignment objects
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddeactivate(UnitAssignment unitAssignment, fr.paris.lutece.portal.service.plugin.Plugin plugin) Deactivates a unit assignmentvoiddeactivateByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Deactivate the unit assignments associated to the specified resourcevoiddeleteByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Deletes the unit assignments associated to the specified resourcegetListByFilter(UnitAssignmentFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments from filter.voidinsert(UnitAssignment unitAssignment, fr.paris.lutece.portal.service.plugin.Plugin plugin) Inserts a new record in the table.loadCurrentAssignment(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the current unit assignment for the specified couple {resource id, resource type}selectByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments associated to the specified couple {resource id, resource type}selectByUnit(int nIdUnit, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments associated to the specified unitselectIdResourceByFilter(UnitAssignmentFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin) Finds id resource from filter.
-
Field Details
-
BEAN_NAME
- See Also:
-
-
Constructor Details
-
UnitAssignmentDAO
public UnitAssignmentDAO()
-
-
Method Details
-
insert
public void insert(UnitAssignment unitAssignment, fr.paris.lutece.portal.service.plugin.Plugin plugin) Inserts a new record in the table.- Specified by:
insertin interfaceIUnitAssignmentDAO- Parameters:
unitAssignment- the unit assignment to insertplugin- the Plugin
-
loadCurrentAssignment
public UnitAssignment loadCurrentAssignment(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the current unit assignment for the specified couple {resource id, resource type}- Specified by:
loadCurrentAssignmentin interfaceIUnitAssignmentDAO- Parameters:
nIdResource- The resource idstrResourceType- the resource typeplugin- the Plugin- Returns:
- The current unit assignment
-
deactivate
public void deactivate(UnitAssignment unitAssignment, fr.paris.lutece.portal.service.plugin.Plugin plugin) Deactivates a unit assignment- Specified by:
deactivatein interfaceIUnitAssignmentDAO- Parameters:
unitAssignment- the unit assignment to deactivateplugin- the Plugin
-
selectByResource
public List<UnitAssignment> selectByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments associated to the specified couple {resource id, resource type}- Specified by:
selectByResourcein interfaceIUnitAssignmentDAO- Parameters:
nIdResource- the resource idstrResourceType- the resource typeplugin- the plugin- Returns:
- the list of unit assignments
-
selectByUnit
public List<UnitAssignment> selectByUnit(int nIdUnit, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments associated to the specified unit- Specified by:
selectByUnitin interfaceIUnitAssignmentDAO- Parameters:
nIdUnit- the unit idplugin- the plugin- Returns:
- the list of unit assignments
-
selectIdResourceByFilter
public List<Integer> selectIdResourceByFilter(UnitAssignmentFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin) Finds id resource from filter.- Specified by:
selectIdResourceByFilterin interfaceIUnitAssignmentDAO- Parameters:
filter- the filterplugin- the plugin- Returns:
- the list of id resource
-
getListByFilter
public List<UnitAssignment> getListByFilter(UnitAssignmentFilter filter, fr.paris.lutece.portal.service.plugin.Plugin plugin) Loads the unit assignments from filter.- Specified by:
getListByFilterin interfaceIUnitAssignmentDAO- Parameters:
filter- the filterplugin- the plugin- Returns:
- the list of unit assignments
-
deactivateByResource
public void deactivateByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Deactivate the unit assignments associated to the specified resource- Specified by:
deactivateByResourcein interfaceIUnitAssignmentDAO- Parameters:
nIdResource- The resource idstrResourceType- The resource typeplugin- The plugin
-
deleteByResource
public void deleteByResource(int nIdResource, String strResourceType, fr.paris.lutece.portal.service.plugin.Plugin plugin) Description copied from interface:IUnitAssignmentDAODeletes the unit assignments associated to the specified resource- Specified by:
deleteByResourcein interfaceIUnitAssignmentDAO- Parameters:
nIdResource- The resource idstrResourceType- The resource typeplugin- The plugin
-