|
ABLE 2.3.0 07/13/2005 14:21:00 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objectcom.ibm.able.data.AbleLiteral
com.ibm.able.data.AbleTypedVariableCompoundLiteral
This class performs a sequence of field access and method invocations starting on an AbleTypedVariable. This literal behaves somewhat differently from other AbleLiterals, in that is not strictly a constant, it invokes the same methods on the same typed variable, but the underlying Object being invoked may change during the course of a ruleset evaluation.
Any nested dot notation field references or method calls get parsed and turned into an instance of this class. Any number of arguments may appear in the source statement.
| Field Summary | |
|---|---|
protected java.util.Vector |
myLiterals
The list of typed field and method literals. |
protected AbleTypedVariable |
myTypedVariable
The typed variable to which this method belongs. |
| Constructor Summary | |
|---|---|
AbleTypedVariableCompoundLiteral(AbleTypedVariableCompoundLiteral theLiteral,
AbleTypedVariable theReplacementVariable,
java.util.Vector theLiterals)
Create a copy of this method literal with replacement args |
|
AbleTypedVariableCompoundLiteral(AbleTypedVariable theTypedVariable,
java.util.Vector theLiterals)
Create a new Able data method object with the specified information. |
|
| Method Summary | |
|---|---|
java.lang.String |
arlCRdString()
Return a formal ARL "clause read" string that describes this data object. |
AbleLiteral |
bitwiseAND(AbleRd theRhs)
Bitwise AND the current value of this data object with the current value of theRhs. |
AbleLiteral |
bitwiseNOT(AbleRd theRhs)
Bitwise NOT: unary complement of the current value of this data object. |
AbleLiteral |
bitwiseOR(AbleRd theRhs)
Bitwise OR the current value of this data object with the current value of theRhs. |
AbleLiteral |
bitwiseShiftLeft(AbleRd theRhs)
Bitwise Shift Left the current value of this data object by the current value of theRhs. |
AbleLiteral |
bitwiseShiftRight(AbleRd theRhs)
Bitwise Shift Right the current value of this data object by the current value of theRhs. |
AbleLiteral |
bitwiseShiftRightZeroFill(AbleRd theRhs)
Bitwise Shift Right with Zero Fill the current value of this data object by the current value of theRhs. |
AbleLiteral |
bitwiseXOR(AbleRd theRhs)
Bitwise XOR: exclusive OR the current value of this data object with the current value of theRhs. |
boolean |
cmpEq(AbleRd theRhs)
Comparison, equal to: compare the current value of this data object to the current value of theRhs. |
boolean |
cmpGt(AbleRd theRhs)
Comparison, greater than: compare the current value of this data object to the current value of theRhs. |
boolean |
cmpGtEq(AbleRd theRhs)
Comparison, greater than or equal to: compare the current value of this data object to the current value of theRhs. |
boolean |
cmpLt(AbleRd theRhs)
Comparison, less than: compare the current value of this data object to the current value of theRhs. |
boolean |
cmpLtEq(AbleRd theRhs)
Comparison, less than or equal to: compare the current value of this data object to the current value of theRhs. |
boolean |
cmpNeq(AbleRd theRhs)
Comparison, not equal to: compare the current value of this data object to the current value of theRhs. |
AbleLiteral |
compDivide(AbleRd theRhs)
Compute, divide the current value of this data object by the current value of theRhs. |
AbleLiteral |
compMinus(AbleRd theRhs)
Compute, subtract the current value of theRhs from the current value of this object. |
AbleLiteral |
compModulo(AbleRd theRhs)
Compute, modulo - divide (without remainder) the current int value of this data object by the current value of theRhs. |
AbleLiteral |
compMultiply(AbleRd theRhs)
Compute, multiply the current value of this data object to the current value of theRhs. |
AbleLiteral |
compPlus(AbleRd theRhs)
Compute, add or concatenate the current value of this data object to the current value of theRhs. |
AbleLiteral |
createMatchLiteral(java.util.Hashtable replacementVars)
Create a duplicate of this method literal using replacement vars |
boolean |
equals(java.lang.Object otherObject)
|
boolean |
getBooleanValue()
Retrieve the value of this data object as a boolean value. |
int |
getDataType()
Retrieve the data type of this data object. |
java.lang.Class |
getDataTypeClass()
Retrieve the Class of the underlying return value; that is, the value returned by last field or method. |
java.lang.String |
getDataTypeClassName()
Retrieve the Class name of the underlying return value; that is, the value returned by last field or method. |
AbleFuzzySet |
getFuzzyValue()
Retrieve the value of this data object as a fuzzy value. |
java.lang.Object |
getGenericValue()
Retrieve the value of this data object as an Object. |
java.util.Vector |
getLiterals()
The list of literals that make up this compound literals |
double |
getNumericValue()
Retrieve the value of this data object as a numeric value. |
java.util.BitSet |
getReferents()
Retrieve the Ids of the variables to which this data object refers, if any. |
java.lang.Class |
getReturnType()
Get the data type of the value returned from the associated method invocation. |
java.lang.String |
getStringValue()
Retrieve the value of this data object as a string value. |
java.lang.String |
getTemplateString(java.util.Vector theTemplateVars)
Retrieve a text format string for use by rule templates. |
AbleTypedVariable |
getTypedVariable()
Retrieve the typed variable |
AbleLiteral |
getValue()
Retrieve the value of this data object as a literal. |
java.util.HashSet |
getVariableReferences()
Retrieve the set of variables (if any) referenced by this expression (and subexpressions) |
int |
hashCode()
|
boolean |
isConstant()
Returns true if this AbleRd object is a constant value false, if it does not. |
boolean |
logicalAND(AbleRd theRhs)
Logical AND the current value of this data object with the current value of theRhs. |
boolean |
logicalNOT(AbleRd theRhs)
Logical NOT: complement the current value of this data object. |
boolean |
logicalOR(AbleRd theRhs)
Logical OR the current value of this data object with the current value of theRhs. |
java.lang.String |
traceString(int theTraceStringFlavor)
Retrieve a string describing (the contents of) the object. |
protected java.lang.String |
trcString(int theTraceStringFlavor)
|
java.lang.String |
xmlCRdString()
Return a formal XML "clause read" string that describes this data object. |
protected java.lang.String |
xmlCRdStringArgs(AbleTypedVariableCompoundLiteral theLit)
|
| Methods inherited from class com.ibm.able.data.AbleLiteral |
|---|
cmpIs, compUnaryMinus, getDataTypeAsString, getReferent, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected AbleTypedVariable myTypedVariable
This field is initialized to null and changed by the constructor when a new typed variable method is created.
protected java.util.Vector myLiterals
| Constructor Detail |
public AbleTypedVariableCompoundLiteral(AbleTypedVariable theTypedVariable,
java.util.Vector theLiterals)
throws AbleDataException
theTypedVariable - A typed variable that contains the following field.
theLiterals - A list of AbleRd objects whose runtime values will be
passed to the user-defined function as arguments. Each
converted argument will be a Boolean, a Double, a
String, or an Object, depending on the type of each
AbleRd object in the argument list. The list can be
empty, but it must never be null.
public AbleTypedVariableCompoundLiteral(AbleTypedVariableCompoundLiteral theLiteral,
AbleTypedVariable theReplacementVariable,
java.util.Vector theLiterals)
throws AbleDataException
| Method Detail |
public AbleLiteral createMatchLiteral(java.util.Hashtable replacementVars)
public java.lang.String arlCRdString()
arlCRdString in interface AbleRdarlCRdString in class AbleLiteralpublic java.lang.String xmlCRdString()
xmlCRdString in interface AbleRdxmlCRdString in class AbleLiteralprotected java.lang.String xmlCRdStringArgs(AbleTypedVariableCompoundLiteral theLit)
public java.lang.String getTemplateString(java.util.Vector theTemplateVars)
getTemplateString in interface AbleRdgetTemplateString in class AbleLiteraltheTemplateVars - An ordered list of template variables referenced by this rule.
public java.util.BitSet getReferents()
getReferents in interface AbleRdgetReferents in class AbleLiteral
public boolean getBooleanValue()
throws AbleDataException
getBooleanValue in interface AbleRdgetBooleanValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
a boolean value.
public AbleFuzzySet getFuzzyValue()
throws AbleDataException
getFuzzyValue in interface AbleRdgetFuzzyValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
a fuzzy value.
public java.lang.Object getGenericValue()
throws AbleDataException
getGenericValue in interface AbleRdgetGenericValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
an Object.
public double getNumericValue()
throws AbleDataException
getNumericValue in interface AbleRdgetNumericValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
a numeric value.
public java.lang.String getStringValue()
throws AbleDataException
getStringValue in interface AbleRdgetStringValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
a string value.
public AbleLiteral getValue()
throws AbleDataException
getValue in interface AbleRdgetValue in class AbleLiteralAbleDataException - If the value of this object cannot be represented as
a literal.
public boolean cmpEq(AbleRd theRhs)
throws AbleDataException
"==" is used for numeric and boolean compares; equals() is used for Object compares; and equals() is used for String compares.
cmpEq in interface AbleRdcmpEq in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean cmpGt(AbleRd theRhs)
throws AbleDataException
">" is used for numeric compares; Collator.compare() is used for String compares. Use of other data types on the left-hand side causes an exception.
cmpGt in interface AbleRdcmpGt in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean cmpGtEq(AbleRd theRhs)
throws AbleDataException
">=" is used for numeric compares; Collator.compare() is used for String compares. Use of other data types on the left-hand side causes an exception.
cmpGtEq in interface AbleRdcmpGtEq in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean cmpLt(AbleRd theRhs)
throws AbleDataException
"<" is used for numeric compares; Collator.compare() is used for String compares. Use of other data types on the left-hand side causes an exception.
cmpLt in interface AbleRdcmpLt in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean cmpLtEq(AbleRd theRhs)
throws AbleDataException
"<=" is used for numeric compares; Collator.compare() is used for String compares. Use of other data types on the left-hand side causes an exception.
cmpLtEq in interface AbleRdcmpLtEq in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean cmpNeq(AbleRd theRhs)
throws AbleDataException
"!=" is used for numeric and boolean compares; ! equals() is used for Object compares; and ! Collator.equals() is used for String compares.
cmpNeq in interface AbleRdcmpNeq in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral compPlus(AbleRd theRhs)
throws AbleDataException
"+" is used for numeric addtion and String concatenation.
compPlus in interface AbleRdcompPlus in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral compMinus(AbleRd theRhs)
throws AbleDataException
"-" is used for numeric subtraction.
compMinus in interface AbleRdcompMinus in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral compMultiply(AbleRd theRhs)
throws AbleDataException
"*" is used for numeric multiplication.
compMultiply in interface AbleRdcompMultiply in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral compDivide(AbleRd theRhs)
throws AbleDataException
"/" is used for numeric division.
compDivide in interface AbleRdcompDivide in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral compModulo(AbleRd theRhs)
throws AbleDataException
"%" is used for integer division without remainder.
compModulo in interface AbleRdcompModulo in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean logicalAND(AbleRd theRhs)
throws AbleDataException
"&&" is used for boolean AND.
logicalAND in interface AbleRdlogicalAND in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean logicalOR(AbleRd theRhs)
throws AbleDataException
"||" is used for boolean OR.
logicalOR in interface AbleRdlogicalOR in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public boolean logicalNOT(AbleRd theRhs)
throws AbleDataException
"!" is used for boolean NOT.
logicalNOT in interface AbleRdlogicalNOT in class AbleLiteraltheRhs - The right-hand side of the comparison.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseAND(AbleRd theRhs)
throws AbleDataException
"&" is used for bitwise AND.
bitwiseAND in interface AbleRdbitwiseAND in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseOR(AbleRd theRhs)
throws AbleDataException
"|" is used for bitwise OR.
bitwiseOR in interface AbleRdbitwiseOR in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseXOR(AbleRd theRhs)
throws AbleDataException
"^" is used for bitwise XOR.
bitwiseXOR in interface AbleRdbitwiseXOR in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseNOT(AbleRd theRhs)
throws AbleDataException
"~" is used for bitwise NOT or complement.
bitwiseNOT in interface AbleRdbitwiseNOT in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseShiftLeft(AbleRd theRhs)
throws AbleDataException
"&&" is used for boolean AND.
bitwiseShiftLeft in interface AbleRdbitwiseShiftLeft in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseShiftRight(AbleRd theRhs)
throws AbleDataException
">>" is used for bitwise shift right.
bitwiseShiftRight in interface AbleRdbitwiseShiftRight in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.
public AbleLiteral bitwiseShiftRightZeroFill(AbleRd theRhs)
throws AbleDataException
">>" is used for bitwise shift right with zero fill.
bitwiseShiftRightZeroFill in interface AbleRdbitwiseShiftRightZeroFill in class AbleLiteraltheRhs - The right-hand side of the operation.
AbleDataException - If the right-hand side cannot be converted (if
necessary) and compared to this data object.public AbleTypedVariable getTypedVariable()
public java.lang.Class getReturnType()
throws java.rmi.RemoteException
java.rmi.RemoteExceptionpublic java.lang.String traceString(int theTraceStringFlavor)
traceString in interface AbleRdtraceString in class AbleLiteraltheTraceStringFlavor - An Able.TraceStringFlavor value.
protected java.lang.String trcString(int theTraceStringFlavor)
public int getDataType()
AbleLiteral
getDataType in interface AbleRdgetDataType in class AbleLiteralAbleRd.getDataType()public boolean equals(java.lang.Object otherObject)
public java.util.Vector getLiterals()
public int hashCode()
public java.util.HashSet getVariableReferences()
public java.lang.Class getDataTypeClass()
getDataTypeClass in interface AbleRdgetDataTypeClass in class AbleLiteralpublic java.lang.String getDataTypeClassName()
getDataTypeClassName in interface AbleRdgetDataTypeClassName in class AbleLiteralpublic boolean isConstant()
AbleRd
isConstant in interface AbleRdisConstant in class AbleLiteral
|
ABLE 2.3.0 07/13/2005 14:21:00 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||