ilog.rules.factory
Class IlrArrayElement
- java.lang.Object
-
- ilog.rules.factory.IlrValue
-
- ilog.rules.factory.IlrArrayElement
-
- All Implemented Interfaces:
- IlrAssignable, java.io.Serializable
public final class IlrArrayElement extends IlrValue implements IlrAssignable
This class represents an array element expression. An array element expression is an expression of the formarr[index]. An array element expression is assignable.Warning: Serialized objects of this class will not be compatible with future releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of IBM Decision Server.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description IlrArrayElement(IlrValue array, IlrValue[] indexes)Constructs an array element expression using an array expression and an index expression.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.lang.ObjectexploreAssignable(IlrFactoryExplorer explorer)Explores the array element as an assignable entity and returns an object as a result.java.lang.ObjectexploreValue(IlrFactoryExplorer explorer)Explores the array element as a value and returns an object as a result.IlrValuegetArray()Gets the array value of this expression.IlrValue[]getIndexes()Gets the indexes values of this expression.booleanisAssignableFrom(IlrValue value)Checks whether the array element can be assigned a given value.voidsetIndexes(IlrValue[] indexes)Changes the indexes values of this expression.-
Methods inherited from class ilog.rules.factory.IlrValue
add, divide, getField, getReflect, getType, getXOMType, invokeEquals, isConstant, isEvent, isEventCondition, isNull, multiply, remainder, subtract, testAfter, testAfter, testBefore, testBefore, testEqual, testFalse, testGreaterOrEqual, testGreaterThan, testIn, testInstanceOf, testLessOrEqual, testLessThan, testNotEqual, testNotIn, testOccursin, testTrue, timeof, toNegative, toPositive, toPostfixDecr, toPostfixIncr, toPrefixDecr, toPrefixIncr
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface ilog.rules.factory.IlrAssignable
getType
-
-
-
-
Constructor Detail
-
IlrArrayElement
public IlrArrayElement(IlrValue array, IlrValue[] indexes)
Constructs an array element expression using an array expression and an index expression. The constructed expression is attached to the sameIlrReflectobject asarray.- Parameters:
array- An expression, whose type must be an array.indexes- An array of expressions, whose type must be integer.
-
-
Method Detail
-
getArray
public IlrValue getArray()
Gets the array value of this expression.- Returns:
- The array expression.
-
getIndexes
public IlrValue[] getIndexes()
Gets the indexes values of this expression.- Returns:
- The indexes values.
-
setIndexes
public void setIndexes(IlrValue[] indexes)
Changes the indexes values of this expression.- Parameters:
indexes- The new indexes values.
-
isAssignableFrom
public boolean isAssignableFrom(IlrValue value)
Checks whether the array element can be assigned a given value.- Specified by:
isAssignableFromin interfaceIlrAssignable- Parameters:
value- The value to be assigned to the array element.- Returns:
trueif the assignment is permitted,falseotherwise.
-
exploreValue
public java.lang.Object exploreValue(IlrFactoryExplorer explorer)
Explores the array element as a value and returns an object as a result.- Specified by:
exploreValuein classIlrValue- Parameters:
explorer- The factory explorer.- Returns:
- An object, the result of the exploration, or
nullif the method does not return a value.
-
exploreAssignable
public java.lang.Object exploreAssignable(IlrFactoryExplorer explorer)
Explores the array element as an assignable entity and returns an object as a result.- Specified by:
exploreAssignablein interfaceIlrAssignable- Parameters:
explorer- The factory explorer.- Returns:
- An object, the result of the exploration, or
nullif the method does not return a value.
-
-