Class MTrigger


  • public class MTrigger
    extends java.lang.Object
    Model element for a plan trigger.
    • Field Detail

      • internalevents

        protected java.util.List<MInternalEvent> internalevents
      • messageevents

        protected java.util.List<MMessageEvent> messageevents
        The message events.
      • goals

        protected java.util.List<MGoal> goals
        The goal types.
      • goalmatches

        protected java.util.Map<java.lang.String,​UnparsedExpression> goalmatches
        Goal match expressions that restrict general goal type triggers.
      • goalfinisheds

        protected java.util.List<MGoal> goalfinisheds
        The goal types of finished goals.
      • factaddeds

        protected java.util.List<java.lang.String> factaddeds
        The belief names.
      • factremoveds

        protected java.util.List<java.lang.String> factremoveds
        The belief names.
      • factchangeds

        protected java.util.List<java.lang.String> factchangeds
        The belief names.
      • services

        protected java.util.List<MServiceCall> services
        The service types.
      • messagenames

        protected java.util.List<java.lang.String> messagenames
      • ieventnames

        protected java.util.List<java.lang.String> ieventnames
      • goalnames

        protected java.util.List<java.lang.String> goalnames
      • goalfinishednames

        protected java.util.List<java.lang.String> goalfinishednames
      • goalmatchnames

        protected java.util.Map<java.lang.String,​UnparsedExpression> goalmatchnames
      • condition

        protected MCondition condition
        The trigger condition.
    • Constructor Detail

      • MTrigger

        public MTrigger()
        Create a new trigger.
    • Method Detail

      • getInternalEvents

        public java.util.List<MInternalEvent> getInternalEvents()
        Get the internal events.
      • getMessageEvents

        public java.util.List<MMessageEvent> getMessageEvents()
        Get the message events.
      • getGoals

        public java.util.List<MGoal> getGoals()
        Get the goals.
      • setGoals

        public void setGoals​(java.util.List<MGoal> goals)
        Set the goals.
        Parameters:
        goals - The goals to set
      • addGoal

        public void addGoal​(MGoal goal)
        Add a goal trigger.
      • getGoalFinisheds

        public java.util.List<MGoal> getGoalFinisheds()
        Get the goalfinisheds.
        Returns:
        The goalfinisheds.
      • addGoalFinished

        public void addGoalFinished​(MGoal goal)
        Add a goal finished trigger.
      • addInternalEvent

        public void addInternalEvent​(MInternalEvent event)
      • addMessageEvent

        public void addMessageEvent​(MMessageEvent event)
        Add a message event.
      • addMessageName

        public void addMessageName​(java.lang.String event)
        Add a message event name.
      • getMessageNames

        public java.util.List<java.lang.String> getMessageNames()
        Get the message events.
      • addInternalEventName

        public void addInternalEventName​(java.lang.String event)
        Add an internal event name.
      • getInternalEventNames

        public java.util.List<java.lang.String> getInternalEventNames()
        Get the message events.
      • addGoalFinishedName

        public void addGoalFinishedName​(java.lang.String event)
        Add a goal finished name.
      • getGoalFinishedNames

        public java.util.List<java.lang.String> getGoalFinishedNames()
        Get the goal finished events.
      • addGoalName

        public void addGoalName​(java.lang.String event)
        Add a goal name.
      • getGoalNames

        public java.util.List<java.lang.String> getGoalNames()
        Get the goal events.
      • setGoalNames

        public void setGoalNames​(java.util.List<java.lang.String> goalnames)
        Set the goalnames.
        Parameters:
        goalnames - The goalnames to set
      • addGoalNameMatchExpression

        public void addGoalNameMatchExpression​(java.lang.String goalname,
                                               UnparsedExpression match)
        Add a goal match before preprecessing (i.e. unresolved name).
      • getGoalNameMatchExpressions

        public java.util.Map<java.lang.String,​UnparsedExpression> getGoalNameMatchExpressions()
        Get goal match expressions for preprecessing.
      • addGoalMatchExpression

        public void addGoalMatchExpression​(java.lang.String goalname,
                                           UnparsedExpression match)
        Add a goal name.
      • getGoalMatchExpression

        public UnparsedExpression getGoalMatchExpression​(MGoal mgoal)
        Get a goal match expression.
      • addFactAdded

        public void addFactAdded​(java.lang.String fact)
        Add a fact added belief trigger.
      • addFactRemoved

        public void addFactRemoved​(java.lang.String fact)
        Add a fact removed belief trigger.
      • addFactChanged

        public void addFactChanged​(java.lang.String fact)
        Add a fact changed belief trigger.
      • getFactAddeds

        public java.util.List<java.lang.String> getFactAddeds()
        Get the fact added triggers (belief set names).
      • getFactRemoveds

        public java.util.List<java.lang.String> getFactRemoveds()
        Get the fact removed triggers (belief set names).
      • getFactChangeds

        public java.util.List<java.lang.String> getFactChangeds()
        Get the fact changeds triggers (belief set names).
      • setFactAddeds

        public void setFactAddeds​(java.util.List<java.lang.String> events)
        Set the fact added triggers (belief set names).
      • setFactRemoveds

        public void setFactRemoveds​(java.util.List<java.lang.String> events)
        Set the fact removed triggers (belief set names).
      • setFactChangeds

        public void setFactChangeds​(java.util.List<java.lang.String> events)
        Set the fact changeds triggers (belief set names).
      • addService

        public void addService​(MServiceCall service)
        Add a service trigger.
      • getServices

        public java.util.List<MServiceCall> getServices()
        Get the fact service calls.
      • getCondition

        public MCondition getCondition()
        Get the condition.
      • setCondition

        public void setCondition​(MCondition condition)
        Set the condition.