net.sourceforge.cilib.container
Interface Array

All Known Implementing Classes:
MultiDimensionalArray, StandardArray

public interface Array

Very basic array abstraction.


Method Summary
<E> E
get(int index)
          Get the element at the provided index.
<E> void
set(E object, int index)
          Set the element at index.
 int size()
          Obtain the current size of the array structure.
 

Method Detail

get

<E> E get(int index)
Get the element at the provided index.

Type Parameters:
E - The generic type.
Parameters:
index - The index of the desired element.
Returns:
The element at index, if available.

set

<E> void set(E object,
             int index)
Set the element at index.

Type Parameters:
E - The generic type.
Parameters:
object - The object to place within the array.
index - The index to set the object at.

size

int size()
Obtain the current size of the array structure.

Returns:
The array length.


Copyright © 2009 CIRG. All Rights Reserved.