|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.wpi.ebob.internal.inspect.AbstractNode
edu.wpi.ebob.internal.inspect.FieldNode
public class FieldNode
represents a IField
in a tree.
Field Summary | |
---|---|
private IField |
field
the field to display in the tree. |
private boolean |
hasCheckedForChildren
we only want to check for children once. |
private boolean |
hasRetrievedValue
we only want to retrieve the value once. |
private IObject |
obj
the object that this field belongs to. |
private IObject |
value
the value of the field field in object obj . |
Fields inherited from class edu.wpi.ebob.internal.inspect.AbstractNode |
---|
children |
Constructor Summary | |
---|---|
FieldNode(IObject obj,
IField field)
creates a new node in the tree representing a field. |
Method Summary | |
---|---|
Node[] |
getChildren()
returns the child nodes of this node, represented as objects. |
org.eclipse.swt.graphics.Image |
getImage()
returns the image that should be shown for this node. |
java.lang.String |
getName()
the text label for this node. |
IClass |
getType()
returns the Class object associated with this node. |
IObject |
getValue()
the underlying value for this node. |
java.lang.String |
getValueAsString()
returns the toString() of Node.getValue() . |
boolean |
hasChildren()
|
boolean |
isModifiable()
|
void |
setValue(IObject newValue)
sets the value of the field. |
Methods inherited from class edu.wpi.ebob.internal.inspect.AbstractNode |
---|
addChild, getParent, setParent, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface edu.wpi.ebob.internal.inspect.Node |
---|
getParent, setParent |
Field Detail |
---|
private IField field
private boolean hasCheckedForChildren
private boolean hasRetrievedValue
private IObject obj
private IObject value
field
in object obj
.
Constructor Detail |
---|
public FieldNode(IObject obj, IField field)
obj
- the object that this field belongs to.field
- the field to display in the tree.Method Detail |
---|
public Node[] getChildren()
Node
getChildren
in interface Node
getChildren
in class AbstractNode
Node.getChildren()
public org.eclipse.swt.graphics.Image getImage()
Node
getImage
in interface Node
getImage
in class AbstractNode
null
Node.getImage()
public java.lang.String getName()
Node
getName
in interface Node
Node.getName()
public IClass getType()
Node
Class
object associated with this node.
getType
in interface Node
Node.getType()
public IObject getValue()
Node
getValue
in interface Node
Node.getValue()
public java.lang.String getValueAsString()
AbstractNode
Node.getValue()
.
getValueAsString
in interface Node
getValueAsString
in class AbstractNode
Node.getValueAsString()
public boolean hasChildren()
hasChildren
in interface Node
hasChildren
in class AbstractNode
true
if the object is non-null and any of the
following are true:
Node.hasChildren()
public boolean isModifiable()
isModifiable
in interface ModifiableNode
true
if and only if this object can be modified.ModifiableNode.isModifiable()
public void setValue(IObject newValue)
setValue
in interface ModifiableNode
newValue
- the new value for this field.IField
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |