jeops.conflict
Class ConflictSetElement

java.lang.Object
  |
  +--jeops.conflict.ConflictSetElement

public class ConflictSetElement
extends java.lang.Object

An element present in the conflict set.

Version:
0.02 07 Apr 2000 The local declarations are now stored as a two-dimensional array, which stores their dependencies with the regular declarations.
Author:
Carlos Figueira Filho (csff@di.ufpe.br)

Constructor Summary
ConflictSetElement(int ruleIndex, java.lang.Object[] objects, java.lang.Object[][] localObjects)
          Class constructor.
 
Method Summary
 boolean equals(java.lang.Object obj)
          Compares this object with the given one.
 java.lang.Object[][] getLocalObjects()
          Returns the objects bound to the locally declared variables.
 java.lang.Object[] getObjects()
          Returns the objects bound to the declared variables.
 int getRuleIndex()
          Returns the index of the fireable rule.
 boolean isDeclared(java.lang.Object obj)
          Checks whether a given object is one of the objects bound to the declared variables in this element.
 boolean isLocallyDeclared(java.lang.Object obj)
          Checks whether a given object is one of the objects bound to the locally declared variables in this element.
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConflictSetElement

public ConflictSetElement(int ruleIndex,
                          java.lang.Object[] objects,
                          java.lang.Object[][] localObjects)
Class constructor.
Parameters:
ruleIndex - the index of the fireable rule.
objects - the objects bound to the declared variables.
localOjects - the the dependency table between the objects bound to the to the locally declared variables and the objects bound to the normal declarations.
Method Detail

getRuleIndex

public int getRuleIndex()
Returns the index of the fireable rule.
Returns:
the index of the fireable rule.

getObjects

public java.lang.Object[] getObjects()
Returns the objects bound to the declared variables.
Returns:
the objects bound to the declared variables.

isDeclared

public boolean isDeclared(java.lang.Object obj)
Checks whether a given object is one of the objects bound to the declared variables in this element.
Parameters:
obj - the object to be checked.
Returns:
true if the given object bound to one of the declared variables in this element; false otherwise.

getLocalObjects

public java.lang.Object[][] getLocalObjects()
Returns the objects bound to the locally declared variables.
Returns:
the objects bound to the locally declared variables.

isLocallyDeclared

public boolean isLocallyDeclared(java.lang.Object obj)
Checks whether a given object is one of the objects bound to the locally declared variables in this element.
Parameters:
obj - the object to be checked.
Returns:
true if the given object bound to one of the locally declared variables in this element; false otherwise.

equals

public boolean equals(java.lang.Object obj)
Compares this object with the given one.
Overrides:
equals in class java.lang.Object
Parameters:
obj - the object to be compared
Returns:
true if the two objects represent the same conflict set element; false otherwise.