public interface Access<V>
| Modifier and Type | Field and Description |
|---|---|
static boolean |
JAVA_8 |
| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(V value)
Test if collection contains value.
|
boolean |
isEmpty()
Test if empty.
|
Iterator<V> |
iterator()
Get the elements in order.
|
Iterator<V> |
reverseIterator()
Get the elements in reverse order.
|
boolean |
reverseVisit(ConditionalVisitor<V> visitor)
Visit all elements in reverse order until
visitor.visit() returns true; |
void |
reverseVisit(Visitor<V> visitor)
Visit all elements in reverse order.
|
int |
size()
Get the number of elements in the collection.
|
boolean |
visit(ConditionalVisitor<V> visitor)
Visit all elements in order until
visitor.visit() returns true; |
void |
visit(Visitor<V> visitor)
Visit all elements in order.
|
boolean isEmpty()
isEmpty() is guaranteed to be an O(1)
operation; it should always be used in preference to
size() == 0, as the latter may have cost up to O(n);int size()
size() may have cost O(1), O(log(n) up
to O(n).boolean contains(V value)
value - Iterator<V> reverseIterator()
boolean visit(ConditionalVisitor<V> visitor)
visitor.visit() returns true;visitor - visitor.visit() returned true;
otherwise falsevoid reverseVisit(Visitor<V> visitor)
visitor - boolean reverseVisit(ConditionalVisitor<V> visitor)
visitor.visit() returns true;visitor - visitor.visit() returned true;
otherwise falseCopyright © 2015. All rights reserved.