public final class Identifiables
extends java.lang.Object
Identifiable
objects.Modifier and Type | Method and Description |
---|---|
boolean |
contains(Identifiable<?> identifiable)
Checks whether the specified
Identifiable exists in this collection. |
boolean |
containsIdentifiableWithLongName(java.lang.String longName)
Checks for existence of an
Identifiable in this collection with the specified longName . |
boolean |
containsKey(java.lang.String identifier)
Checks whether this collection contains the
Identifiable whose identfier matches that specified in the argument |
Identifiable |
find(java.lang.String longName)
Returns the first occurrence of an
Identifiable object with the specified longName that is contained in this collection. |
Identifiable<?> |
get(int index)
Returns the
Identifiable object at the specified index that is contained in this collection. |
Identifiable<?> |
get(java.lang.String identifier)
Returns the
Identifiable object with the specified identifier that is contained in this collection. |
int |
getCount()
Returns the count of items in this collection.
|
java.util.Iterator<Identifiable<?>> |
iterator() |
java.util.stream.Stream<Identifiable<?>> |
stream() |
java.lang.String |
toString() |
public java.util.stream.Stream<Identifiable<?>> stream()
public java.util.Iterator<Identifiable<?>> iterator()
iterator
in interface java.lang.Iterable<Identifiable<?>>
public Identifiable<?> get(int index) throws java.lang.IndexOutOfBoundsException
Identifiable
object at the specified index that is contained in this collection.index
- the index of the Identifiable
to return from the collection, >= 0
and <
collection sizeIdentifiable
object at the specified indexjava.lang.IndexOutOfBoundsException
- if the index is < 0
or >=
countpublic Identifiable<?> get(java.lang.String identifier) throws UnknownIdentifierException
Identifiable
object with the specified identifier that is contained in this collection.identifier
- the identifier of the collection member to returnIdentifiable
subclass with the specified identifierUnknownIdentifierException
- if the object identified by the Identifier parameter can't be foundpublic Identifiable find(java.lang.String longName)
Identifiable
object with the specified longName that is contained in this collection.longName
- the longName of the Identifiable to return, not nullIdentifiable
subclass with the specified longName, can be nullpublic boolean contains(Identifiable<?> identifiable)
Identifiable
exists in this collection.identifiable
- the Identifiable
to check, not nulltrue
if the specified identifiable exists
, false
otherwisepublic boolean containsKey(java.lang.String identifier)
Identifiable
whose identfier matches that specified in the argumentidentifier
- the identifier of the member to check for occurrence in the collection, not nullpublic boolean containsIdentifiableWithLongName(java.lang.String longName)
Identifiable
in this collection with the specified longName
.longName
- the value of longName
to check, nullable since longName
can be nullIdentifiable
with the specified longName
exists in this collection, otherwise falsepublic java.lang.String toString()
toString
in class java.lang.Object
public int getCount()