Modifier and Type | Method and Description |
---|---|
Iterable<String> |
asIterable()
Return an Iterable view so that this Iterator can be used in for each
statements.
|
boolean |
atParentPath()
Returns true if this iterator is currently at a parent path as opposed
to the initial path given to the constructor
|
static PathParentIterator |
forAll(String path)
Return a new PathParentIterator that iterates from the
given path to all parents.
|
static PathParentIterator |
forPathOnly(String path)
Return a new PathParentIterator that only returns the given path - i.e.
|
boolean |
hasNext() |
String |
next() |
void |
remove() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEachRemaining
public static PathParentIterator forAll(String path)
path
- initial pathpublic static PathParentIterator forPathOnly(String path)
path
- initial pathpublic Iterable<String> asIterable()
public boolean atParentPath()
Copyright © 2008–2020 The Apache Software Foundation. All rights reserved.