IterableExtension<T> extension
- on
-
- Iterable<
T>
- Iterable<
Properties
-
firstOption
→ Option<
T> -
Available on Iterable<
Returns the first element as an Option. If the list is empty, it will return None.T> , provided by the IterableExtension extensionno setter -
head
→ Option<
T> -
Available on Iterable<
Returns the first element as an Option. If the list is empty, it will return None.T> , provided by the IterableExtension extensionno setter -
init
→ Option<
Iterable< T> > -
Available on Iterable<
Returns all the of elements except the last.T> , provided by the IterableExtension extensionno setter -
lastOption
→ Option<
T> -
Available on Iterable<
Returns the last element as an Option. If the list is empty, it will return None.T> , provided by the IterableExtension extensionno setter -
tail
→ Option<
Iterable< T> > -
Available on Iterable<
Returns all the of elements except the first.T> , provided by the IterableExtension extensionno setter
Methods
-
append(
T t) → Iterable< T> -
Available on Iterable<
Returns a new iterable with the given element appended to the end.T> , provided by the IterableExtension extension -
elementAtOption(
int index) → Option< T> -
Available on Iterable<
Get the element at the givenT> , provided by the IterableExtension extensionindex
as an Option. If the element does not exist, it will return None. -
firstWhereOption(
bool predicate(T element)) → Option< T> -
Available on Iterable<
The first element satisfyingT> , provided by the IterableExtension extensionpredicate
as an Option. -
prepend(
T t) → Iterable< T> -
Available on Iterable<
Returns a new iterable with the given element prepended to the start.T> , provided by the IterableExtension extension