gov.nasa.arc.brahms.vm.data
Class ExpressionOperand

java.lang.Object
  extended by gov.nasa.arc.brahms.vm.data.ExpressionOperand

public class ExpressionOperand
extends java.lang.Object

The ExpressionOperand represents an operand resulting from instantiating an expression located at the left hand side of a comparison that is used in a consequence, detectable, or transfer definitions.

Version:
$Revision: 1.1 $ $Date: 2009/11/23 20:40:48 $ $Author: rnado $
Author:
Bob Nado

Constructor Summary
ExpressionOperand()
          Constructor, creates a new ExpressionOperand.
ExpressionOperand(java.lang.Object object)
          Constructor, creates a new ExpressionOperand specifying the resulting value after evaluating the expression.
ExpressionOperand(java.lang.Object object, Attribute attribute)
          Constructor, creates a new ExpressionOperand specifying the resulting operand after evaluating the expression.
ExpressionOperand(java.lang.Object object, Attribute attribute, java.lang.Object index)
          Constructor, creates a new ExpressionOperand specifying the resulting operand after evaluating the expression.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Tests whether two ExpressionOperands are equal
 Attribute getAttribute()
          Returns the attribute for the expression operand
 java.lang.Object getCollectionIndex()
          Returns the collection index for the expression operand.
 java.lang.Object getObject()
          Returns the object for the operand
 boolean isUnknown()
          Determines whether the object of this expression operand is the Unknown
 void setAttribute(Attribute attr)
          Sets the expression operand attribute
 void setCollectionIndex(java.lang.Object index)
          Sets the collection index for the expression operand.
 void setObject(java.lang.Object object)
          Sets the expression operand object
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExpressionOperand

public ExpressionOperand()
Constructor, creates a new ExpressionOperand.


ExpressionOperand

public ExpressionOperand(java.lang.Object object)
Constructor, creates a new ExpressionOperand specifying the resulting value after evaluating the expression.

Parameters:
object - the object of the operand

ExpressionOperand

public ExpressionOperand(java.lang.Object object,
                         Attribute attribute)
Constructor, creates a new ExpressionOperand specifying the resulting operand after evaluating the expression.

Parameters:
object - the object of the operand
attribute - the attribute of the operand

ExpressionOperand

public ExpressionOperand(java.lang.Object object,
                         Attribute attribute,
                         java.lang.Object index)
Constructor, creates a new ExpressionOperand specifying the resulting operand after evaluating the expression.

Parameters:
object - the object of the operand
attribute - the attribute of the operand
index - the collection index of the operand
Method Detail

getObject

public final java.lang.Object getObject()
Returns the object for the operand

Returns:
Object the expression object

setObject

public final void setObject(java.lang.Object object)
Sets the expression operand object

Parameters:
object - the expression operand object

getAttribute

public Attribute getAttribute()
Returns the attribute for the expression operand

Returns:
Attribute the expression operand attribute

setAttribute

public void setAttribute(Attribute attr)
Sets the expression operand attribute

Parameters:
attr - the expression operand Attribute

getCollectionIndex

public java.lang.Object getCollectionIndex()
Returns the collection index for the expression operand.

Returns:
Object one of String, Integer

setCollectionIndex

public void setCollectionIndex(java.lang.Object index)
Sets the collection index for the expression operand.

Parameters:
index - the collection index

isUnknown

public boolean isUnknown()
Determines whether the object of this expression operand is the Unknown

Returns:
boolean true if the object is Unknown, else false

equals

public final boolean equals(java.lang.Object obj)
Tests whether two ExpressionOperands are equal

Overrides:
equals in class java.lang.Object
Parameters:
obj - the ExpressionOperand to be tested with for equality
Returns:
true if the two expression operands are equal, false otherwise


Copyright © 1997-2012 All Rights Reserved.