|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.snmp4j.agent.request.SubRequestIteratorSupport
public class SubRequestIteratorSupport
This support class allows to implement a SubRequestIterator
instance based on an Iterator that iterates on
SubRequest instances.
| Constructor Summary | |
|---|---|
SubRequestIteratorSupport(java.util.Iterator subRequests)
Creates a SubRequestIterator that decorates an
Iterator. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Returns true if there are more sub-requests to process. |
protected SubRequest |
mapToSubRequest(java.lang.Object element)
Returns the SubRequest contained or represented by the
supplied object (element of the iterator). |
SubRequest |
next()
Gets the next sub-request that is pending. |
void |
remove()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SubRequestIteratorSupport(java.util.Iterator subRequests)
SubRequestIterator that decorates an
Iterator.
subRequests - an Iterator on SubRequest instances or instances
of other objects if mapToSubRequest(Object element) is
implemented (overwritten) accordingly.| Method Detail |
|---|
public boolean hasNext()
SubRequestIteratortrue if there are more sub-requests to process.
In other words, returns true if next would return an element
rather than throwing an exception.
hasNext in interface java.util.Iterator<SubRequest>hasNext in interface SubRequestIteratortrue if there are more sub-requests.public SubRequest next()
SubRequestIterator
next in interface java.util.Iterator<SubRequest>next in interface SubRequestIteratorSubRequest instance.public void remove()
remove in interface java.util.Iterator<SubRequest>protected SubRequest mapToSubRequest(java.lang.Object element)
SubRequest contained or represented by the
supplied object (element of the iterator). The default implementation
simply casts the supplied object to SubRequest.
element - an Object from which a SubRequest can be deduced.
SubRequest instance.
|
Copyright 2005-2010 Frank Fock (SNMP4J.org) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||