edu.wpi.ebob.internal.inspect
Class ArrayItemNode
java.lang.Object
edu.wpi.ebob.internal.inspect.AbstractNode
edu.wpi.ebob.internal.inspect.ArrayItemNode
- All Implemented Interfaces:
- ModifiableNode, Node
public class ArrayItemNode
- extends AbstractNode
- implements ModifiableNode
- Author:
- Liam Morley
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
hasCheckedForChildren
private boolean hasCheckedForChildren
index
private int index
type
private IClass type
value
private IObject value
array
private IArray array
ArrayItemNode
public ArrayItemNode(IArray valArray,
int index,
IClass type)
getChildren
public Node[] getChildren()
- Description copied from interface:
Node
- returns the child nodes of this node, represented as objects.
- Specified by:
getChildren
in interface Node
- Overrides:
getChildren
in class AbstractNode
- See Also:
Node.getChildren()
getImage
public org.eclipse.swt.graphics.Image getImage()
- Description copied from interface:
Node
- returns the image that should be shown for this node.
- Specified by:
getImage
in interface Node
- Overrides:
getImage
in class AbstractNode
- Returns:
- the parent node's icon
- See Also:
Node.getImage()
getName
public java.lang.String getName()
- Description copied from interface:
Node
- the text label for this node.
- Specified by:
getName
in interface Node
- See Also:
Node.getName()
getType
public IClass getType()
- Description copied from interface:
Node
- returns the
Class
object associated with this node.
- Specified by:
getType
in interface Node
- See Also:
Node.getType()
getValue
public IObject getValue()
- Description copied from interface:
Node
- the underlying value for this node.
- Specified by:
getValue
in interface Node
- See Also:
Node.getValue()
getValueAsString
public java.lang.String getValueAsString()
- Description copied from class:
AbstractNode
- returns the toString() of
Node.getValue()
.
- Specified by:
getValueAsString
in interface Node
- Overrides:
getValueAsString
in class AbstractNode
- See Also:
Node.getValueAsString()
hasChildren
public boolean hasChildren()
- Specified by:
hasChildren
in interface Node
- Overrides:
hasChildren
in class AbstractNode
- Returns:
true
if the object is non-null and any of the
following are true:
- the object is an array with a length greater than 0
- the object is not-primitive and has at least one declared
field
- See Also:
Node.hasChildren()
isModifiable
public boolean isModifiable()
- Specified by:
isModifiable
in interface ModifiableNode
- Returns:
true
if and only if this object can be modified.- See Also:
ModifiableNode.isModifiable()
setValue
public void setValue(IObject newValue)
- Specified by:
setValue
in interface ModifiableNode
- See Also:
ModifiableNode.setValue(IObject)