Interface StochasticLabelledPetriNetSemantics

    • Method Detail

      • getNumberOfTransitions

        int getNumberOfTransitions()
      • setInitialState

        void setInitialState()
        (Re)set the semantics to the initial state.
      • executeTransition

        void executeTransition​(int transition)
        Update the state to reflect execution of the transition.
        Parameters:
        transition -
      • getEnabledTransitions

        java.util.BitSet getEnabledTransitions()
        Parameters:
        state -
        Returns:
        an array of indices of the transitions that are enabled. May be changed and stored by the caller.
      • isFinalState

        boolean isFinalState()
        Returns:
        whether the current state is a final state.
      • getState

        byte[] getState()
        Returns:
        a copy of the current state.
      • setState

        void setState​(byte[] state)
        Set a copy of the given state.
        Parameters:
        state -
      • isTransitionSilent

        boolean isTransitionSilent​(int transition)
        Parameters:
        transition -
        Returns:
        whether the given transition is silent
      • getTransitionLabel

        java.lang.String getTransitionLabel​(int transition)
        Only call when it is certain that the transition is not a silent transition.
        Parameters:
        transition -
        Returns:
        the label of the transition.
      • getTransitionWeight

        double getTransitionWeight​(int transition)
        Parameters:
        transition -
        Returns:
        the weight of the transition. This might depend on the state.
      • getTotalWeightOfEnabledTransitions

        double getTotalWeightOfEnabledTransitions()
        Parameters:
        enabledTransitions -
        Returns:
        the sum of the weight of the enabled transitions