Class Condition

java.lang.Object
org.opendope.conditions.Condition
All Implemented Interfaces:
Evaluable

public class Condition
extends java.lang.Object
implements Evaluable

Java class for anonymous complex type.

The following schema fragment specifies the expected content contained within this class.

 <complexType>
   <complexContent>
     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
       <choice>
         <element ref="{http://opendope.org/conditions}xpathref"/>
         <element ref="{http://opendope.org/conditions}and"/>
         <element ref="{http://opendope.org/conditions}or"/>
         <element ref="{http://opendope.org/conditions}not"/>
       </choice>
       <attribute name="id" use="required" type="{http://www.w3.org/2001/XMLSchema}ID" />
       <attribute name="name" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="description" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="comments" type="{http://www.w3.org/2001/XMLSchema}string" />
       <attribute name="source" type="{http://www.w3.org/2001/XMLSchema}string" />
     </restriction>
   </complexContent>
 </complexType>
 
  • Field Summary

    Fields 
    Modifier and Type Field Description
    protected java.lang.String comments  
    protected java.lang.String description  
    protected java.lang.String id  
    protected java.lang.String name  
    protected Evaluable particle  
    protected java.lang.String source  
  • Constructor Summary

    Constructors 
    Constructor Description
    Condition()  
  • Method Summary

    Modifier and Type Method Description
    boolean evaluate​(WordprocessingMLPackage pkg, java.util.Map<java.lang.String,​CustomXmlPart> customXmlDataStorageParts, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)  
    java.lang.String getComments()
    Gets the value of the comments property.
    java.lang.String getDescription()
    Gets the value of the description property.
    java.lang.String getId()
    Gets the value of the id property.
    java.lang.String getName()
    Gets the value of the name property.
    Evaluable getParticle()
    Gets the value of the particle property.
    java.lang.String getSource()
    Gets the value of the source property.
    void listXPaths​(java.util.List<Xpaths.Xpath> theList, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
    List the XPaths used in this condition.
    void mapIds​(java.util.Map<java.lang.String,​java.lang.String> xpathIdMap, java.util.Map<java.lang.String,​java.lang.String> conditionIdMap)
    Map the IDs used in this condition to new values; useful for merging ConditionParts.
    Condition repeat​(java.lang.String xpathBase, int index, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
    Create a condition for this instance of a repeat.
    void setComments​(java.lang.String value)
    Sets the value of the comments property.
    void setDescription​(java.lang.String value)
    Sets the value of the description property.
    void setDomToXPathMap​(DomToXPathMap domToXPathMap)  
    void setId​(java.lang.String value)
    Sets the value of the id property.
    void setName​(java.lang.String value)
    Sets the value of the name property.
    void setParticle​(Evaluable value)
    Sets the value of the particle property.
    void setSource​(java.lang.String value)
    Sets the value of the source property.
    java.lang.String toString​(java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
    Build the XPath expression

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • particle

      protected Evaluable particle
    • id

      protected java.lang.String id
    • name

      protected java.lang.String name
    • description

      protected java.lang.String description
    • comments

      protected java.lang.String comments
    • source

      protected java.lang.String source
  • Constructor Details

  • Method Details

    • getParticle

      public Evaluable getParticle()
      Gets the value of the particle property.
      Returns:
      possible object is Xpathref And Or Not
    • setParticle

      public void setParticle​(Evaluable value)
      Sets the value of the particle property.
      Parameters:
      value - allowed object is Xpathref And Or Not
    • evaluate

      public boolean evaluate​(WordprocessingMLPackage pkg, java.util.Map<java.lang.String,​CustomXmlPart> customXmlDataStorageParts, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
      Specified by:
      evaluate in interface Evaluable
    • setDomToXPathMap

      public void setDomToXPathMap​(DomToXPathMap domToXPathMap)
    • listXPaths

      public void listXPaths​(java.util.List<Xpaths.Xpath> theList, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
      Description copied from interface: Evaluable
      List the XPaths used in this condition.
      Specified by:
      listXPaths in interface Evaluable
    • mapIds

      public void mapIds​(java.util.Map<java.lang.String,​java.lang.String> xpathIdMap, java.util.Map<java.lang.String,​java.lang.String> conditionIdMap)
      Map the IDs used in this condition to new values; useful for merging ConditionParts.
      Specified by:
      mapIds in interface Evaluable
      Parameters:
      xpathIdMap -
      conditionIdMap -
      Since:
      3.0.0
    • toString

      public java.lang.String toString​(java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
      Description copied from interface: Evaluable
      Build the XPath expression
      Specified by:
      toString in interface Evaluable
      Returns:
    • repeat

      public Condition repeat​(java.lang.String xpathBase, int index, java.util.Map<java.lang.String,​Condition> conditionsMap, java.util.Map<java.lang.String,​Xpaths.Xpath> xpathsMap)
      Description copied from interface: Evaluable
      Create a condition for this instance of a repeat.
      Specified by:
      repeat in interface Evaluable
      Returns:
    • getId

      public java.lang.String getId()
      Gets the value of the id property.
      Returns:
      possible object is String
    • setId

      public void setId​(java.lang.String value)
      Sets the value of the id property.
      Parameters:
      value - allowed object is String
    • getName

      public java.lang.String getName()
      Gets the value of the name property.
      Returns:
      possible object is String
    • setName

      public void setName​(java.lang.String value)
      Sets the value of the name property.
      Parameters:
      value - allowed object is String
    • getDescription

      public java.lang.String getDescription()
      Gets the value of the description property.
      Returns:
      possible object is String
    • setDescription

      public void setDescription​(java.lang.String value)
      Sets the value of the description property.
      Parameters:
      value - allowed object is String
    • getComments

      public java.lang.String getComments()
      Gets the value of the comments property.
      Returns:
      possible object is String
    • setComments

      public void setComments​(java.lang.String value)
      Sets the value of the comments property.
      Parameters:
      value - allowed object is String
    • getSource

      public java.lang.String getSource()
      Gets the value of the source property.
      Returns:
      possible object is String
    • setSource

      public void setSource​(java.lang.String value)
      Sets the value of the source property.
      Parameters:
      value - allowed object is String