net.java.properties
Interface ListPropertyI<T>

All Superinterfaces:
CollectionPropertyI<T>, PropertyI<java.util.Collection<T>>
All Known Implementing Classes:
ListProperty

public interface ListPropertyI<T>
extends CollectionPropertyI<T>

Extends CollectionPropertyI to add access with an integer index.


Method Summary
 Result<T> add(T value, int ix)
          Adds an element at specified index in the list.
 T get(int ix)
          Returns the element at the specified index.
 Result<T> removeIndex(int ix)
          Removed the element at the specified index in the list.
 Result<T> set(T value, int ix)
          Sets (exchanges) an element at specified index in the list.
 
Methods inherited from interface net.java.properties.CollectionPropertyI
add, addAll, contains, containsAll, iterator, remove, removeAll, size
 
Methods inherited from interface net.java.properties.PropertyI
get, set
 

Method Detail

get

T get(int ix)
Returns the element at the specified index.

Parameters:
ix - The index for which to return the element. If >= size or < 0 an IndexOutOfBoundsException will be thrown.
Returns:
The element at ix.

set

Result<T> set(T value,
              int ix)
Sets (exchanges) an element at specified index in the list.

Parameters:
value - The value to set.
ix - The index for which to set the element. If >= size or < 0 an IndexOutOfBoundsException will be thrown.
Returns:
The result of the set.

add

Result<T> add(T value,
              int ix)
Adds an element at specified index in the list.

Parameters:
value - The value to add.
ix - The index that the index will be added at. If > size or < 0 an IndexOutOfBoundsException will be thrown. If ix == size the value will be added last in the list.
Returns:
The result of the add.

removeIndex

Result<T> removeIndex(int ix)
Removed the element at the specified index in the list.

Parameters:
ix - The index for which the element should be removed. If > size or < 0 an IndexOutOfBoundsException will be thrown.
Returns:
The result of the removal.


Copyright © 2007 MiG InfoCom AB. All Rights Reserved.