|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.directory.api.ldap.model.cursor.AbstractCursor<E>
org.apache.directory.api.ldap.model.cursor.SingletonCursor<E>
E - The type of element on which this cursor will iteratepublic class SingletonCursor<E>
A Cursor over a single element.
| Constructor Summary | |
|---|---|
SingletonCursor(E singleton)
Creates a new instance of SingletonCursor. |
|
SingletonCursor(E singleton,
Comparator<E> comparator)
Creates a new instance of SingletonCursor, with its associated comparator |
|
| Method Summary | |
|---|---|
void |
after(E element)
Prepares this Cursor, so a subsequent call to Cursor#previous() with a true return value, will have positioned the Cursor on a dataSet element equal to or less than the element argument but not greater. |
void |
afterLast()
Positions this Cursor after the last element. |
boolean |
available()
Determines whether or not a call to get() will succeed. |
void |
before(E element)
Prepares this Cursor, so a subsequent call to Cursor#next() with a true return value, will have positioned the Cursor on a dataSet element equal to or less than the element argument but not greater. |
void |
beforeFirst()
Positions this Cursor before the first element. |
void |
close()
Closes this Cursor and frees any resources it my have allocated. |
void |
close(Exception cause)
Closes this Cursor and frees any resources it my have allocated. |
boolean |
first()
Positions this Cursor at the first element. |
E |
get()
Gets the object at the current position. |
boolean |
isAfterLast()
Is this Cursor positioned after the last element. |
boolean |
isBeforeFirst()
Is this Cursor positioned before the first element. |
boolean |
isFirst()
Is this Cursor positioned at the first element. |
boolean |
isLast()
Is this Cursor positioned at the last element. |
boolean |
last()
Positions this Cursor at the last element. |
boolean |
next()
Advances this Cursor to the next position. |
boolean |
previous()
Advances this Cursor to the previous position. |
| Methods inherited from class org.apache.directory.api.ldap.model.cursor.AbstractCursor |
|---|
checkNotClosed, isClosed, iterator, setClosureMonitor, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SingletonCursor(E singleton)
singleton - The unique element to store into this cursor
public SingletonCursor(E singleton,
Comparator<E> comparator)
singleton - The unique element to store into this cursorcomparator - The associated comparator| Method Detail |
|---|
public boolean available()
public void before(E element)
throws LdapException,
CursorException,
IOException
element - the element to be positioned before
LdapException
CursorException
IOException
public void after(E element)
throws LdapException,
CursorException,
IOException
element - the element to be positioned after
LdapException
CursorException
IOException
public void beforeFirst()
throws LdapException,
CursorException,
IOException
LdapException
CursorException
IOException
public void afterLast()
throws LdapException,
CursorException,
IOException
LdapException
CursorException
IOException
public boolean first()
throws LdapException,
CursorException,
IOException
LdapException
CursorException
IOException
public boolean last()
throws LdapException,
CursorException,
IOException
LdapException
CursorException
IOExceptionpublic boolean isFirst()
isFirst in interface Cursor<E>isFirst in class AbstractCursor<E>public boolean isLast()
isLast in interface Cursor<E>isLast in class AbstractCursor<E>public boolean isAfterLast()
isAfterLast in interface Cursor<E>isAfterLast in class AbstractCursor<E>public boolean isBeforeFirst()
isBeforeFirst in interface Cursor<E>isBeforeFirst in class AbstractCursor<E>
public boolean previous()
throws LdapException,
CursorException,
IOException
LdapException
CursorException
IOException
public boolean next()
throws LdapException,
CursorException,
IOException
LdapException - if we have get any LDAP exception while operating
the cursor
CursorException - if there are problems advancing to this Cursor to
the next position, or if this Cursor is closed
IOException - If we have had any IO Exception
public E get()
throws CursorException,
IOException
CursorException - if the object at this Cursor's current position
cannot be retrieved, or if this Cursor is closed
IOException - If we have had any IO Exceptionpublic void close()
close in interface Cursor<E>close in class AbstractCursor<E>public void close(Exception cause)
close in interface Cursor<E>close in class AbstractCursor<E>cause - exception thrown when this Cursor is accessed after close
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||