org.eclipse.cdt.debug.internal.core.model
Class CIndexedValue

java.lang.Object
  extended by org.eclipse.core.runtime.PlatformObject
      extended by org.eclipse.cdt.debug.internal.core.model.CDebugElement
          extended by org.eclipse.cdt.debug.internal.core.model.AbstractCValue
              extended by org.eclipse.cdt.debug.internal.core.model.CIndexedValue
All Implemented Interfaces:
ICDebugElement, ICDebugElementStatus, ICValue, org.eclipse.core.runtime.IAdaptable, org.eclipse.debug.core.model.IDebugElement, org.eclipse.debug.core.model.IIndexedValue, org.eclipse.debug.core.model.IValue

public class CIndexedValue
extends AbstractCValue
implements org.eclipse.debug.core.model.IIndexedValue

A value containing an array of variables.


Field Summary
 
Fields inherited from interface org.eclipse.cdt.debug.core.model.ICDebugElementStatus
ERROR, OK, WARNING
 
Constructor Summary
CIndexedValue(AbstractCVariable parent, org.eclipse.cdt.debug.core.cdi.model.type.ICDIArrayValue cdiValue, int offset, int size)
          Constructor for CIndexedValue.
 
Method Summary
 void dispose()
           
 int getInitialOffset()
           
 java.lang.String getReferenceTypeName()
           
 int getSize()
           
 ICType getType()
           
 java.lang.String getValueString()
          Please note that this function returns the address of the array, not the contents of the array, as long as the underlying ICDIArrayValue is an instance of ICDIPointerValue.
 org.eclipse.debug.core.model.IVariable getVariable(int offset)
           
 org.eclipse.debug.core.model.IVariable[] getVariables()
           
 org.eclipse.debug.core.model.IVariable[] getVariables(int offset, int length)
           
 boolean hasVariables()
           
 boolean isAllocated()
           
 
Methods inherited from class org.eclipse.cdt.debug.internal.core.model.AbstractCValue
evaluateAsExpression, getParentVariable
 
Methods inherited from class org.eclipse.cdt.debug.internal.core.model.CDebugElement
createChangeEvent, createCreateEvent, createResumeEvent, createSuspendEvent, createTerminateEvent, fireChangeEvent, fireCreationEvent, fireResumeEvent, fireSuspendEvent, fireTerminateEvent, getAdapter, getCDISession, getCDITarget, getCurrentStateInfo, getDebugTarget, getLaunch, getMessage, getModelIdentifier, getSeverity, getState, isOK, notSupported, requestFailed, requestFailed, targetRequestFailed, targetRequestFailed
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.debug.core.model.IDebugElement
getDebugTarget, getLaunch, getModelIdentifier
 
Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
 
Methods inherited from interface org.eclipse.cdt.debug.core.model.ICDebugElement
getCurrentStateInfo, getState
 

Constructor Detail

CIndexedValue

public CIndexedValue(AbstractCVariable parent,
                     org.eclipse.cdt.debug.core.cdi.model.type.ICDIArrayValue cdiValue,
                     int offset,
                     int size)
Constructor for CIndexedValue.

Method Detail

dispose

public void dispose()
Specified by:
dispose in class AbstractCValue

getType

public ICType getType()
               throws org.eclipse.debug.core.DebugException
Specified by:
getType in interface ICValue
Throws:
org.eclipse.debug.core.DebugException

getReferenceTypeName

public java.lang.String getReferenceTypeName()
                                      throws org.eclipse.debug.core.DebugException
Specified by:
getReferenceTypeName in interface org.eclipse.debug.core.model.IValue
Throws:
org.eclipse.debug.core.DebugException

getValueString

public java.lang.String getValueString()
                                throws org.eclipse.debug.core.DebugException
Please note that this function returns the address of the array, not the contents of the array, as long as the underlying ICDIArrayValue is an instance of ICDIPointerValue. Otherwise, it returns an empty string.

Specified by:
getValueString in interface org.eclipse.debug.core.model.IValue
Throws:
org.eclipse.debug.core.DebugException
See Also:
IValue.getValueString()

isAllocated

public boolean isAllocated()
                    throws org.eclipse.debug.core.DebugException
Specified by:
isAllocated in interface org.eclipse.debug.core.model.IValue
Throws:
org.eclipse.debug.core.DebugException

getVariables

public org.eclipse.debug.core.model.IVariable[] getVariables()
                                                      throws org.eclipse.debug.core.DebugException
Specified by:
getVariables in interface org.eclipse.debug.core.model.IValue
Throws:
org.eclipse.debug.core.DebugException

hasVariables

public boolean hasVariables()
                     throws org.eclipse.debug.core.DebugException
Specified by:
hasVariables in interface org.eclipse.debug.core.model.IValue
Throws:
org.eclipse.debug.core.DebugException

getVariable

public org.eclipse.debug.core.model.IVariable getVariable(int offset)
                                                   throws org.eclipse.debug.core.DebugException
Specified by:
getVariable in interface org.eclipse.debug.core.model.IIndexedValue
Throws:
org.eclipse.debug.core.DebugException

getVariables

public org.eclipse.debug.core.model.IVariable[] getVariables(int offset,
                                                             int length)
                                                      throws org.eclipse.debug.core.DebugException
Specified by:
getVariables in interface org.eclipse.debug.core.model.IIndexedValue
Throws:
org.eclipse.debug.core.DebugException

getSize

public int getSize()
            throws org.eclipse.debug.core.DebugException
Specified by:
getSize in interface org.eclipse.debug.core.model.IIndexedValue
Throws:
org.eclipse.debug.core.DebugException

getInitialOffset

public int getInitialOffset()
Specified by:
getInitialOffset in interface org.eclipse.debug.core.model.IIndexedValue