org.beanfabrics.model
Interface SelectedKeys<E>

Type Parameters:
E - the key type
All Superinterfaces:
java.util.Collection<E>, java.lang.Iterable<E>, java.util.Set<E>

public interface SelectedKeys<E>
extends java.util.Set<E>

See Also:
MapPM

Method Summary
 E getFirst()
          Returns the first (topmost) selected key.
 boolean setAll(java.util.Collection<?> c)
          Sets this selection to contain exactly the specified keys.
 boolean setAll(E... keys)
          Sets this selection to contain exactly the specified keys.
 java.util.Collection<E> toCollection()
          Returns a new Collection with all selected keys.
 
Methods inherited from interface java.util.Set
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 

Method Detail

toCollection

java.util.Collection<E> toCollection()
Returns a new Collection with all selected keys. Modification on this collection will not influence the original selection.

Returns:
a new Collection with all selected keys

getFirst

E getFirst()
Returns the first (topmost) selected key.

Returns:
the first (topmost) selected key

setAll

boolean setAll(java.util.Collection<?> c)
Sets this selection to contain exactly the specified keys.

Parameters:
c -
Returns:
true if this set did not already contain exactly the specified keys

setAll

boolean setAll(E... keys)
Sets this selection to contain exactly the specified keys.

Parameters:
keys -
Returns:
true if this set did not already contain exactly the specified keys