Interface AdjacencyMaps
-
- All Superinterfaces:
Iterable<AdjacencyMap>
- All Known Implementing Classes:
PrunedAdjacencyMaps,SimpleAdjacencyMaps
public interface AdjacencyMaps extends Iterable<AdjacencyMap>
AnAdjacencyMapsobject contains a number ofAdjacencyMapobjects and can be used to represent the changes in an AdjacencyMap over time or to track the adjacency components of a graph over some other metric.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default voidadd(AdjacencyMap adjacencyMap)Add a newAdjacencyMap.List<AdjacencyMap>asList()Get a representation of the current AdjacencyMaps object as aList.default booleanempty()Returntrueif this AdjacencyMaps object is empty, otherwisefalse.default AdjacencyMapget(int n)Retrieve the nthAdjacencyMap.default Iterator<AdjacencyMap>iterator()default StringprettyPrint()Print theAdjacencyMapsobject in an easily readable format.default intsize()Return the number ofAdjacencyMaps present in the AdjacencyMaps object.-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Method Detail
-
add
default void add(AdjacencyMap adjacencyMap)
Add a newAdjacencyMap.- Parameters:
adjacencyMap- the AdjacencyMap to add
-
get
default AdjacencyMap get(int n)
Retrieve the nthAdjacencyMap.- Parameters:
n- the index of the adjacency map to retrieve- Returns:
- the nth AdjacencyMap
-
size
default int size()
Return the number ofAdjacencyMaps present in the AdjacencyMaps object.Depending on the context, this could refer to the number of hops present, or the number of timesteps etc.
- Returns:
- the size of the AdjacencyMaps object
-
empty
default boolean empty()
Returntrueif this AdjacencyMaps object is empty, otherwisefalse.- Returns:
- the empty state of this object
-
prettyPrint
default String prettyPrint()
Print theAdjacencyMapsobject in an easily readable format.- Returns:
- a prettily printed
Stringrepresentation of the AdjacencyMap object.
-
iterator
default Iterator<AdjacencyMap> iterator()
- Specified by:
iteratorin interfaceIterable<AdjacencyMap>
-
asList
List<AdjacencyMap> asList()
Get a representation of the current AdjacencyMaps object as aList.- Returns:
- a
Listrepresentation of the current AdjacencyMaps object
-
-