Class ActivityPrecedence

  • All Implemented Interfaces:

    
    public class ActivityPrecedence
    
                        

    A class modeling precedence relationships among activities

    • Constructor Detail

      • ActivityPrecedence

        ActivityPrecedence(List<String> preActs, List<String> postActs, String preType, String postType, Matrix preParams, Matrix postParams)
        Constructs an ActivityPrecedence with the specified parameters.
        Parameters:
        preActs - the list of preceding activity names
        postActs - the list of following activity names
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
        preParams - the parameters for the preceding activities
        postParams - the parameters for the following activities
      • ActivityPrecedence

        ActivityPrecedence(List<String> preActs, List<String> postActs, String preType, String postType, Matrix preParams)
        Constructs an ActivityPrecedence with the specified parameters, without postParams.
        Parameters:
        preActs - the list of preceding activity names
        postActs - the list of following activity names
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
        preParams - the parameters for the preceding activities
      • ActivityPrecedence

        ActivityPrecedence(List<String> preActs, List<String> postActs, String preType, String postType)
        Constructs an ActivityPrecedence with the specified parameters, without preParams and postParams.
        Parameters:
        preActs - the list of preceding activity names
        postActs - the list of following activity names
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
      • ActivityPrecedence

        ActivityPrecedence(List<String> preActs, List<String> postActs, String preType)
        Constructs an ActivityPrecedence with the specified parameters, assuming POST_SEQ as postType.
        Parameters:
        preActs - the list of preceding activity names
        postActs - the list of following activity names
        preType - the type of the precedence relationship before the activity
      • ActivityPrecedence

        ActivityPrecedence(List<String> preActs, List<String> postActs)
        Constructs an ActivityPrecedence with the specified parameters, assuming PRE_SEQ as preType and POST_SEQ as postType.
        Parameters:
        preActs - the list of preceding activity names
        postActs - the list of following activity names
    • Method Detail

      • fromActivities

         static ActivityPrecedence fromActivities(List<Activity> preActs, List<Activity> postActs, String preType, String postType, Matrix preParams, Matrix postParams)

        Creates an ActivityPrecedence with Activity objects.

        Parameters:
        preActs - the list of preceding activities
        postActs - the list of following activities
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
        preParams - the parameters for the preceding activities
        postParams - the parameters for the following activities
        Returns:

        an ActivityPrecedence object

      • fromActivities

         static ActivityPrecedence fromActivities(List<Activity> preActs, List<Activity> postActs, String preType, String postType, Matrix preParams)

        Creates an ActivityPrecedence with Activity objects, without postParams.

        Parameters:
        preActs - the list of preceding activities
        postActs - the list of following activities
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
        preParams - the parameters for the preceding activities
        Returns:

        an ActivityPrecedence object

      • fromActivities

         static ActivityPrecedence fromActivities(List<Activity> preActs, List<Activity> postActs, String preType, String postType)

        Creates an ActivityPrecedence with Activity objects, without preParams and postParams.

        Parameters:
        preActs - the list of preceding activities
        postActs - the list of following activities
        preType - the type of the precedence relationship before the activity
        postType - the type of the precedence relationship after the activity
        Returns:

        an ActivityPrecedence object

      • fromActivities

         static ActivityPrecedence fromActivities(List<Activity> preActs, List<Activity> postActs, String preType)

        Creates an ActivityPrecedence with Activity objects, assuming POST_SEQ as postType.

        Parameters:
        preActs - the list of preceding activities
        postActs - the list of following activities
        preType - the type of the precedence relationship before the activity
        Returns:

        an ActivityPrecedence object

      • fromActivities

         static ActivityPrecedence fromActivities(List<Activity> preActs, List<Activity> postActs)

        Creates an ActivityPrecedence with Activity objects, assuming PRE_SEQ as preType and POST_SEQ as postType.

        Parameters:
        preActs - the list of preceding activities
        postActs - the list of following activities
        Returns:

        an ActivityPrecedence object

      • AndFork

         static ActivityPrecedence AndFork(Activity preAct, List<Activity> postActs)

        Creates an ActivityPrecedence object representing an AND-fork relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        Returns:

        an ActivityPrecedence object

      • AndFork

         static ActivityPrecedence AndFork(String preAct, List<String> postActs)

        Creates an ActivityPrecedence object representing an AND-fork relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        Returns:

        an ActivityPrecedence object

      • AndFork

         static ActivityPrecedence AndFork(String preAct, List<String> postActs, Matrix fanout)

        Creates an ActivityPrecedence object representing an AND-fork relationship with a specified fanout matrix.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        fanout - the fanout matrix
        Returns:

        an ActivityPrecedence object

      • AndFork

         static ActivityPrecedence AndFork(Activity preAct, List<Activity> postActs, Matrix fanout)

        Creates an ActivityPrecedence object representing an AND-fork relationship with a specified fanout matrix.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        fanout - the fanout matrix
        Returns:

        an ActivityPrecedence object

      • AndJoin

         static ActivityPrecedence AndJoin(List<String> preActs, String postAct)

        Creates an ActivityPrecedence object representing an AND-join relationship.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • AndJoin

         static ActivityPrecedence AndJoin(List<Activity> preActs, Activity postAct)

        Creates an ActivityPrecedence object representing an AND-join relationship.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • AndJoin

         static ActivityPrecedence AndJoin(List<Activity> preActs, Activity postAct, Matrix quorum)

        Creates an ActivityPrecedence object representing an AND-join relationship with a specified quorum matrix.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        quorum - the quorum matrix
        Returns:

        an ActivityPrecedence object

      • AndJoin

         static ActivityPrecedence AndJoin(List<String> preActs, String postAct, Matrix quorum)

        Creates an ActivityPrecedence object representing an AND-join relationship with a specified quorum matrix.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        quorum - the quorum matrix
        Returns:

        an ActivityPrecedence object

      • CacheAccess

         static ActivityPrecedence CacheAccess(Activity preAct, List<Activity> postActs)

        Creates an ActivityPrecedence object representing a cache access relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        Returns:

        an ActivityPrecedence object

      • CacheAccess

         static ActivityPrecedence CacheAccess(String preAct, List<String> postActs)

        Creates an ActivityPrecedence object representing a cache access relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(Activity preAct, Activity loopAct, Activity endAct, double nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        loopAct - the activity that is looped
        endAct - the activity after the loop completes
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(String preAct, String loopAct, String endAct, double nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        loopAct - the activity that is looped
        endAct - the activity after the loop completes
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(Activity preAct, List<Activity> postActs, double nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        postActs - a list with loopAct and endAct (see 4-parameter Loop constructor)
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(String preAct, List<String> postActs, double nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        postActs - a list with loopAct and endAct (see 4-parameter Loop constructor)
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(Activity preAct, List<Activity> postActs, Matrix nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        postActs - a list with loopAct and endAct (see 4-parameter Loop constructor)
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(String preAct, List<String> postActs, Matrix nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        postActs - a list with loopAct and endAct (see 4-parameter Loop constructor)
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(Activity preAct, Activity loopAct, Activity endAct, Matrix nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        loopAct - the activity that is looped
        endAct - the activity after the loop completes
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • Loop

         static ActivityPrecedence Loop(String preAct, String loopAct, String endAct, Matrix nloops)

        Creates an ActivityPrecedence object representing a loop relationship.

        Parameters:
        preAct - the preceding activity
        loopAct - the activity that is looped
        endAct - the activity after the loop completes
        nloops - the number of loops
        Returns:

        an ActivityPrecedence object

      • OrFork

         static ActivityPrecedence OrFork(Activity preAct, List<Activity> postActs, Matrix probs)

        Creates an ActivityPrecedence object representing an OR-fork relationship with a specified probability matrix.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        probs - the probability matrix
        Returns:

        an ActivityPrecedence object

      • OrFork

         static ActivityPrecedence OrFork(String preAct, List<String> postActs, Matrix probs)

        Creates an ActivityPrecedence object representing an OR-fork relationship with a specified probability matrix.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        probs - the probability matrix
        Returns:

        an ActivityPrecedence object

      • OrJoin

         static ActivityPrecedence OrJoin(List<String> preActs, String postAct)

        Creates an ActivityPrecedence object representing an OR-join relationship.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • OrJoin

         static ActivityPrecedence OrJoin(List<Activity> preActs, Activity postAct)

        Creates an ActivityPrecedence object representing an OR-join relationship.

        Parameters:
        preActs - the list of preceding activities
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • Serial

         static Array<ActivityPrecedence> Serial(List<out Object> varargin)

        Creates an array of ActivityPrecedence objects representing a sequence.

        Parameters:
        varargin - the list of activity names
        Returns:

        an array of ActivityPrecedence objects

      • Serial

         static ActivityPrecedence Serial(String preAct, String postAct)

        Creates an ActivityPrecedence object representing a sequence relationship.

        Parameters:
        preAct - the preceding activity
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • Serial

         static ActivityPrecedence Serial(Activity preAct, Activity postAct)

        Creates an ActivityPrecedence object representing a sequence relationship.

        Parameters:
        preAct - the preceding activity
        postAct - the following activity
        Returns:

        an ActivityPrecedence object

      • Serial

         static Array<ActivityPrecedence> Serial(Array<Activity> activities)

        Creates an array of ActivityPrecedence objects representing a sequence from varargs.

        Parameters:
        activities - the activities to form a serial sequence
        Returns:

        an array of ActivityPrecedence objects

      • Serial

         static Array<ActivityPrecedence> Serial(Array<String> activities)

        Creates an array of ActivityPrecedence objects representing a sequence from varargs.

        Parameters:
        activities - the activity names to form a serial sequence
        Returns:

        an array of ActivityPrecedence objects

      • Xor

         static ActivityPrecedence Xor(Activity preAct, List<Activity> postActs, Matrix probs)

        Creates an ActivityPrecedence object representing an XOR relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        probs - the probability matrix
        Returns:

        an ActivityPrecedence object

      • Xor

         static ActivityPrecedence Xor(String preAct, List<String> postActs, Matrix probs)

        Creates an ActivityPrecedence object representing an XOR relationship.

        Parameters:
        preAct - the preceding activity
        postActs - the list of following activities
        probs - the probability matrix
        Returns:

        an ActivityPrecedence object

      • getPrecedenceId

         static int getPrecedenceId(String precedence)

        Retrieves the precedence ID based on the precedence type string.

        Parameters:
        precedence - the precedence type string
        Returns:

        the precedence ID