Package org.eclipse.debug.core.model
Interface IValue
-
- All Superinterfaces:
IAdaptable
,IDebugElement
- All Known Subinterfaces:
IIndexedValue
public interface IValue extends IDebugElement
A value represents the value of a variable. A value representing a complex data structure contains variables.An implementation may choose to re-use or discard values on iterative thread suspensions. Clients cannot assume that values are identical or equal across iterative thread suspensions and must check for equality on iterative suspensions if they wish to re-use the objects.
An implementation that preserves equality across iterative suspensions may display more desirable behavior in some clients. For example, if variables are preserved while stepping, a UI client would be able to update the UI incrementally, rather than collapse and redraw the entire list or tree.
Clients may implement this interface.
- See Also:
IVariable
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
getReferenceTypeName()
Returns a description of the type of data this value contains or references.String
getValueString()
Returns this value as aString
.IVariable[]
getVariables()
Returns the visible variables in this value.boolean
hasVariables()
Returns whether this value currently contains any visible variables.boolean
isAllocated()
Returns whether this value is currently allocated.-
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
-
Methods inherited from interface org.eclipse.debug.core.model.IDebugElement
getDebugTarget, getLaunch, getModelIdentifier
-
-
-
-
Method Detail
-
getReferenceTypeName
String getReferenceTypeName() throws DebugException
Returns a description of the type of data this value contains or references.- Returns:
- the name of this value's reference type
- Throws:
DebugException
- if this method fails. Reasons include:- Failure communicating with the VM. The DebugException's status code contains the underlying exception responsible for the failure.
-
getValueString
String getValueString() throws DebugException
Returns this value as aString
.- Returns:
- a String representation of this value
- Throws:
DebugException
- if this method fails. Reasons include:- Failure communicating with the VM. The DebugException's status code contains the underlying exception responsible for the failure.
-
isAllocated
boolean isAllocated() throws DebugException
Returns whether this value is currently allocated.For example, if this value represents an object that has been garbage collected,
false
is returned.- Returns:
- whether this value is currently allocated
- Throws:
DebugException
- if this method fails. Reasons include:- Failure communicating with the VM. The DebugException's status code contains the underlying exception responsible for the failure.
-
getVariables
IVariable[] getVariables() throws DebugException
Returns the visible variables in this value. An empty collection is returned if there are no visible variables.- Returns:
- an array of visible variables
- Throws:
DebugException
- if this method fails. Reasons include:- Failure communicating with the VM. The DebugException's status code contains the underlying exception responsible for the failure.
- Since:
- 2.0
-
hasVariables
boolean hasVariables() throws DebugException
Returns whether this value currently contains any visible variables.- Returns:
- whether this value currently contains any visible variables
- Throws:
DebugException
- if this method fails. Reasons include:- Failure communicating with the debug target. The DebugException's status code contains the underlying exception responsible for the failure.
- Since:
- 2.0
-
-