Class UnitAssignmentService


  • public final class UnitAssignmentService
    extends java.lang.Object
    This 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 UnitAssignment findCurrentAssignment​(int nIdResource, java.lang.String strResourceType)
      Finds the current unit assignment for the specified couple {resource id, resource type}
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 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 id
        strResourceType - 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 id
        strResourceType - 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