Class UnitAssignmentService
- java.lang.Object
-
- fr.paris.lutece.plugins.unittree.service.assignment.UnitAssignmentService
-
public final class UnitAssignmentService extends java.lang.ObjectThis class is the entry point for unit assignment. It provides methods for unit assignment.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.List<UnitAssignment>findAssignments(int nIdResource, java.lang.String strResourceType)Finds the unit assignments associated to the specified couple {resource id, resource type}.static java.util.List<UnitAssignment>findAssignmentsByUnit(int nIdUnit)Finds the resources assigned to the unit .static UnitAssignmentfindCurrentAssignment(int nIdResource, java.lang.String strResourceType)Finds the current unit assignment for the specified couple {resource id, resource type}
-
-
-
Method Detail
-
findCurrentAssignment
public static UnitAssignment findCurrentAssignment(int nIdResource, java.lang.String strResourceType)
Finds the current unit assignment for the specified couple {resource id, resource type}- Parameters:
nIdResource- The resource idstrResourceType- the resource type- Returns:
- the current unit assignment
-
findAssignments
public static java.util.List<UnitAssignment> findAssignments(int nIdResource, java.lang.String strResourceType)
Finds the unit assignments associated to the specified couple {resource id, resource type}.
The unit assignments are sorted by ascending date.
- Parameters:
nIdResource- the resource idstrResourceType- the resource type- Returns:
- the list of unit assignments
-
findAssignmentsByUnit
public static java.util.List<UnitAssignment> findAssignmentsByUnit(int nIdUnit)
Finds the resources assigned to the unit .
The unit assignments are sorted by ascending date.
- Parameters:
nIdUnit- the Unit id- Returns:
- the list of unit assignments
-
-