JavaScript Development Tools
Release 3.2

org.eclipse.wst.jsdt.debug.core.jsdi
Interface ArrayReference

All Superinterfaces:
Mirror, ObjectReference, Value

public interface ArrayReference
extends ObjectReference

Abstract representation of an array.

Since:
1.0
See Also:
ObjectReference, Value
Restriction:
This interface is not intended to be extended by clients.

Method Summary
 Value getValue(int index)
          Returns the Value at the given index in this array.
 List getValues()
          Returns the live list of Values in the array or an empty list.
 int length()
          Returns the current number of Values in this array.
 
Methods inherited from interface org.eclipse.wst.jsdt.debug.core.jsdi.ObjectReference
className, constructor, id, properties, prototype
 
Methods inherited from interface org.eclipse.wst.jsdt.debug.core.jsdi.Value
valueString
 
Methods inherited from interface org.eclipse.wst.jsdt.debug.core.jsdi.Mirror
virtualMachine
 

Method Detail

length

int length()
Returns the current number of Values in this array.

Returns:
the number of Values in the array

getValue

Value getValue(int index)
               throws IndexOutOfBoundsException
Returns the Value at the given index in this array. If the bounds are outside of the array bounds an ArrayIndexOutOfBoundsException is thrown. If there is a null entry in the array NullValue is returned.

This method cannot return null

Parameters:
index - the index of the Value to retrieve
Returns:
the Value at the given index
Throws:
IndexOutOfBoundsException - if the index is outside the bounds of this array. For example if index < 0 or index > length()

getValues

List getValues()
Returns the live list of Values in the array or an empty list.

This method cannot return null

Returns:
the live list of Values in this array or an empty list, never null

JavaScript Development Tools
Release 3.2

Copyright (c) IBM Corp. and others 2000, 2010. All Rights Reserved.