Class SACondition

  • All Implemented Interfaces:
    FAtiMA.Core.wellFormedNames.IGroundable, java.io.Serializable, java.lang.Cloneable

    public class SACondition
    extends FAtiMA.Core.conditions.Condition
    Parses a SACondition in Actions.xml file
    Author:
    Meiyii Lim 2010-04-18
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.Hashtable<java.lang.String,​FAtiMA.Core.wellFormedNames.Symbol> _knownVariables  
      protected java.lang.String _query  
      protected FAtiMA.Core.wellFormedNames.Symbol _value  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void AddKnownVariables​(java.lang.String name, FAtiMA.Core.wellFormedNames.Symbol value)  
      boolean CheckCondition​(FAtiMA.Core.AgentModel am)  
      java.lang.Object clone()  
      java.util.Hashtable<java.lang.String,​FAtiMA.Core.wellFormedNames.Symbol> GetKnownVariables()  
      java.lang.String GetQuery()  
      java.util.ArrayList<FAtiMA.Core.wellFormedNames.SubstitutionSet> GetValidBindings​(FAtiMA.Core.AgentModel am)  
      FAtiMA.Core.wellFormedNames.Name GetValue()  
      protected java.util.ArrayList<FAtiMA.Core.wellFormedNames.Substitution> GetValueBindings​(FAtiMA.Core.AgentModel am)  
      boolean isGrounded()  
      void MakeGround​(FAtiMA.Core.wellFormedNames.Substitution subst)  
      void MakeGround​(java.util.ArrayList<FAtiMA.Core.wellFormedNames.Substitution> bindings)  
      static SACondition ParseSA​(org.xml.sax.Attributes attributes)
      Parses a SpreadActivateCondition given a XML attribute list
      void ReplaceUnboundVariables​(int variableID)  
      • Methods inherited from class FAtiMA.Core.conditions.Condition

        CheckActivation, getName, getToM, hasChangedVerifiability, isVerifiable, setName, setToM, setVerifiable
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • _knownVariables

        protected java.util.Hashtable<java.lang.String,​FAtiMA.Core.wellFormedNames.Symbol> _knownVariables
      • _query

        protected java.lang.String _query
      • _value

        protected FAtiMA.Core.wellFormedNames.Symbol _value
    • Method Detail

      • ParseSA

        public static SACondition ParseSA​(org.xml.sax.Attributes attributes)
        Parses a SpreadActivateCondition given a XML attribute list
        Parameters:
        attributes - - A list of XML attributes
        Returns:
        - the SpreadActivateCondition
      • AddKnownVariables

        public void AddKnownVariables​(java.lang.String name,
                                      FAtiMA.Core.wellFormedNames.Symbol value)
      • CheckCondition

        public boolean CheckCondition​(FAtiMA.Core.AgentModel am)
        Specified by:
        CheckCondition in class FAtiMA.Core.conditions.Condition
      • GetValue

        public FAtiMA.Core.wellFormedNames.Name GetValue()
        Specified by:
        GetValue in class FAtiMA.Core.conditions.Condition
      • GetQuery

        public java.lang.String GetQuery()
      • GetKnownVariables

        public java.util.Hashtable<java.lang.String,​FAtiMA.Core.wellFormedNames.Symbol> GetKnownVariables()
      • GetValueBindings

        protected java.util.ArrayList<FAtiMA.Core.wellFormedNames.Substitution> GetValueBindings​(FAtiMA.Core.AgentModel am)
        Specified by:
        GetValueBindings in class FAtiMA.Core.conditions.Condition
      • GetValidBindings

        public java.util.ArrayList<FAtiMA.Core.wellFormedNames.SubstitutionSet> GetValidBindings​(FAtiMA.Core.AgentModel am)
        Overrides:
        GetValidBindings in class FAtiMA.Core.conditions.Condition
      • clone

        public java.lang.Object clone()
        Specified by:
        clone in class FAtiMA.Core.conditions.Condition
      • MakeGround

        public void MakeGround​(java.util.ArrayList<FAtiMA.Core.wellFormedNames.Substitution> bindings)
        Specified by:
        MakeGround in interface FAtiMA.Core.wellFormedNames.IGroundable
        Overrides:
        MakeGround in class FAtiMA.Core.conditions.Condition
      • MakeGround

        public void MakeGround​(FAtiMA.Core.wellFormedNames.Substitution subst)
        Specified by:
        MakeGround in interface FAtiMA.Core.wellFormedNames.IGroundable
        Overrides:
        MakeGround in class FAtiMA.Core.conditions.Condition
      • ReplaceUnboundVariables

        public void ReplaceUnboundVariables​(int variableID)
        Specified by:
        ReplaceUnboundVariables in interface FAtiMA.Core.wellFormedNames.IGroundable
        Overrides:
        ReplaceUnboundVariables in class FAtiMA.Core.conditions.Condition
      • isGrounded

        public boolean isGrounded()
        Specified by:
        isGrounded in interface FAtiMA.Core.wellFormedNames.IGroundable
        Overrides:
        isGrounded in class FAtiMA.Core.conditions.Condition