edu.wpi.ebob.model
Class ObjectBench.Obj
java.lang.Object
edu.wpi.ebob.model.ObjectBench.Obj
- Enclosing class:
- ObjectBench
private class ObjectBench.Obj
- extends java.lang.Object
Field Summary |
private java.util.Set |
dependents
objects that are dependent on this object. |
private java.util.Set |
dependers
objects that list this object as a dependent. |
private java.lang.String |
name
|
private IObject |
obj
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
name
private java.lang.String name
obj
private IObject obj
dependents
private java.util.Set dependents
- objects that are dependent on this object.
dependers
private java.util.Set dependers
- objects that list this object as a dependent. These references are
saved so that this object can be easily removed as a dependent when
it is removed from the bench.
ObjectBench.Obj
public ObjectBench.Obj(java.lang.String name,
IObject obj)
getName
public java.lang.String getName()
- Returns:
- Returns the name of this object.
getObj
public IObject getObj()
- Returns:
- Returns the object.
getDependents
public java.util.Set getDependents()
- Returns the dependents in a modifiable set.
- Returns:
- the objects (of type Obj) that are dependent on this object.
addDependent
public void addDependent(ObjectBench.Obj dependent)
- Parameters:
dependent
-
removeDependent
public void removeDependent(ObjectBench.Obj dependent)
- Parameters:
dependent
-
dispose
public void dispose()
hasDependents
public boolean hasDependents()
- Returns:
true
if there is another object dependent on
this object, false
otherwise.