sleep.runtime
Interface ScalarArray

All Superinterfaces:
java.io.Serializable
All Known Implementing Classes:
ArgumentArray, ArrayContainer, CollectionWrapper

public interface ScalarArray
extends java.io.Serializable

This interface lets you implement your own data structure behind a scalar array.

To instantiate a custom scalar array:

Scalar temp = SleepUtils.getArrayScalar(new MyScalarArray());

When implementing the following interface, keep in mind you are implementing an interface to an array data structure.


Method Summary
 Scalar add(Scalar value, int index)
           
 Scalar getAt(int index)
           
 Scalar pop()
           
 Scalar push(Scalar value)
           
 Scalar remove(int index)
           
 void remove(Scalar value)
           
 java.util.Iterator scalarIterator()
           
 int size()
           
 void sort(java.util.Comparator compare)
           
 

Method Detail

pop

Scalar pop()

push

Scalar push(Scalar value)

size

int size()

getAt

Scalar getAt(int index)

scalarIterator

java.util.Iterator scalarIterator()

add

Scalar add(Scalar value,
           int index)

remove

void remove(Scalar value)

remove

Scalar remove(int index)

sort

void sort(java.util.Comparator compare)