public class OptionalIterable<T> extends Object implements Iterable<T>
This iterable is intended to be not null, so you can always get items by using iterator. If you need
to check if value was actually provided then use isSupported().
| Constructor and Description |
|---|
OptionalIterable(Iterable<T> iterable) |
| Modifier and Type | Method and Description |
|---|---|
static <T> OptionalIterable<T> |
absent() |
boolean |
isSupported() |
Iterator<T> |
iterator() |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic static <T> OptionalIterable<T> absent()
public Iterator<T> iterator()
iterator in interface Iterable<T>isSupported() is true,
or empty iterator in other case.public boolean isSupported()
Copyright © 2017 Atlassian. All rights reserved.