org.drools.lang.descr
Class LiteralRestrictionDescr

java.lang.Object
  extended by org.drools.lang.descr.BaseDescr
      extended by org.drools.lang.descr.RestrictionDescr
          extended by org.drools.lang.descr.LiteralRestrictionDescr
All Implemented Interfaces:
java.io.Serializable

public class LiteralRestrictionDescr
extends RestrictionDescr

This represents a literal node in the rule language. This is a constraint on a single field of a pattern. The "text" contains the content.

See Also:
Serialized Form

Field Summary
static int TYPE_BOOLEAN
           
static int TYPE_NULL
           
static int TYPE_NUMBER
           
static int TYPE_STRING
           
 
Constructor Summary
LiteralRestrictionDescr(java.lang.String evaluator, java.lang.String text)
           
LiteralRestrictionDescr(java.lang.String evaluator, java.lang.String text, int type)
           
 
Method Summary
 java.lang.String getEvaluator()
           
 int getType()
           
 java.lang.Object getValue()
           
 void setType(int type)
           
 java.lang.String toString()
           
 
Methods inherited from class org.drools.lang.descr.BaseDescr
getColumn, getEndCharacter, getEndColumn, getEndLine, getLine, getStartCharacter, getText, setEndCharacter, setEndLocation, setLocation, setStartCharacter, setText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_NULL

public static final int TYPE_NULL
See Also:
Constant Field Values

TYPE_NUMBER

public static final int TYPE_NUMBER
See Also:
Constant Field Values

TYPE_STRING

public static final int TYPE_STRING
See Also:
Constant Field Values

TYPE_BOOLEAN

public static final int TYPE_BOOLEAN
See Also:
Constant Field Values
Constructor Detail

LiteralRestrictionDescr

public LiteralRestrictionDescr(java.lang.String evaluator,
                               java.lang.String text)

LiteralRestrictionDescr

public LiteralRestrictionDescr(java.lang.String evaluator,
                               java.lang.String text,
                               int type)
Method Detail

getEvaluator

public java.lang.String getEvaluator()

getValue

public java.lang.Object getValue()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getType

public int getType()

setType

public void setType(int type)