Klasse IterableTool
java.lang.Object
ch.nolix.core.independent.containertool.IterableTool
The
IterableTool provides methods to handle Iterables.- Version:
- 2017-12-16
- Autor:
- Silvan Wyss
-
Konstruktorübersicht
Konstruktoren -
Methodenübersicht
Modifizierer und TypMethodeBeschreibungbooleancontainsElement(Iterable<?> iterable, Object element) booleancontainsElementOnce(Iterable<?> iterable, Object element) booleancontainsEqualing(Iterable<?> container, Object object) booleancontainsExactlyOneWithStringRepresentation(Iterable<?> iterable, String stringRepresentation) intgetElementCount(Iterable<?> container) boolean
-
Konstruktordetails
-
IterableTool
public IterableTool()
-
-
Methodendetails
-
containsElement
- Parameter:
iterable-element-- Gibt zurück:
- true if the given container contains the given element, false otherwise.
-
containsElementOnce
- Parameter:
iterable-element-- Gibt zurück:
- true if the given iterable contains the given element exactly 1 time, false otherwise.
-
containsEqualing
- Parameter:
container-object-- Gibt zurück:
- true if the given container contains an element that equals the given object.
-
containsExactlyOneWithStringRepresentation
public boolean containsExactlyOneWithStringRepresentation(Iterable<?> iterable, String stringRepresentation) - Parameter:
iterable-stringRepresentation-- Gibt zurück:
- true if the given iterable contains exactly 1 element with the given stringRepresentation
-
getElementCount
- Parameter:
container-- Gibt zurück:
- the number of elements of the given container.
-
isEmpty
- Parameter:
container-- Gibt zurück:
- true if the given container is not empty.
-