Number of nodes is fixed, links between nodes can be added or removed.
| Modifier and Type | Class and Description |
|---|---|
| public static class | |
| public static interface |
| Modifier and Type | Field and Description |
|---|---|
| private final BinaryMatrix | edgeMatrix
Record Component accessed by edgeMatrix(). the edge matrix. |
| private final FixedDAG. |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static <U> FixedDAG. | |
| public static <U> FixedDAG | |
| pack-priv static <U> FixedDAG | |
| public void | |
| public void | |
| public BinaryMatrix | |
| public final boolean | equals(Object o)
Implements abstract java. Indicates whether some other object is "equal to" this one. |
| public List | |
| private List | |
| public List | |
| public List | Returns: the list of nodes that are heads of the edges sharing the same tail, which is the given nodea node node)Gets the list of nodes that are heads of the edges sharing the same tail, which is the given node. |
| pack-priv static Stream | |
| public List | Returns: the list of nodes without incoming edgesGet the list of nodes without incoming edges. |
| pack-priv static IntStream | |
| public List | Returns: the list of nodes without outgoing edgesGet the list of nodes without outgoing edges. |
| pack-priv static IntStream | |
| pack-priv static Stream | |
| public List | Returns: the list of nodes that are tails of the edges sharing the same head, which is the given nodea node node)Gets the list of nodes that are tails of the edges sharing the same head, which is the given node. |
| public final int | |
| private static boolean | |
| public FixedDAG. | |
| public List | Returns: topologically ordered nodes of this graphReturns topologically ordered nodes of this graph. |
| public final String | toString()
Implements abstract java. Returns a string representation of the record. |
| pack-priv static void | traverseNodes(int nodeIndex, BinaryMatrix edgeMatrix, boolean heads, Function<Integer, Boolean> nodeAccumulator)
|
| edgeMatrix | back to summary |
|---|---|
| private final BinaryMatrix edgeMatrix Record Component accessed by edgeMatrix(). the edge matrix. [i,j] addresses an edge, where 'i' is the index of the head node of the edge in the node container and 'j' is the index of the tail node of the edge in the node container | |
| nodes | back to summary |
|---|---|
| private final FixedDAG. Record Component accessed by nodes(). the node container | |
| FixedDAG | back to summary |
|---|---|
| public FixedDAG(BinaryMatrix edgeMatrix, FixedDAG. | |
| build | back to summary |
|---|---|
| public static <U> FixedDAG. | |
| create | back to summary |
|---|---|
| public static <U> FixedDAG | |
| create | back to summary |
|---|---|
| pack-priv static <U> FixedDAG | |
| dump | back to summary |
|---|---|
| public void dump(Consumer<String> sink) | |
| dumpToStdout | back to summary |
|---|---|
| public void dumpToStdout() | |
| edgeMatrix | back to summary |
|---|---|
| public BinaryMatrix edgeMatrix() Record Component getter of edgeMatrix.
| |
| equals | back to summary |
|---|---|
| public final boolean equals(Object o) Implements abstract java. Doc from java. Indicates whether some other object is "equal to" this one. In addition
to the general contract of
R copy = new R(r.c1(), r.c2(), ..., r.cn());
then it must be the case that r.equals(copy).
| |
| getAllHeadsOf | back to summary |
|---|---|
| public List | |
| getAllNodesOf | back to summary |
|---|---|
| private List | |
| getAllTailsOf | back to summary |
|---|---|
| public List | |
| getHeadsOf | back to summary |
|---|---|
| public List Gets the list of nodes that are heads of the edges sharing the same tail, which is the given node. The returned list is ordered by the indexes of the nodes in the node container of this graph. | |
| getIncomingEdges | back to summary |
|---|---|
| pack-priv static Stream | |
| getNoIncomingEdges | back to summary |
|---|---|
| public List Get the list of nodes without incoming edges. A node without incoming edges is a node that is not a head of any of the edges in the graph. The returned list is ordered by the indexes of the nodes in the node container of this graph.
| |
| getNoIncomingEdges | back to summary |
|---|---|
| pack-priv static IntStream getNoIncomingEdges(BinaryMatrix edgeMatrix) | |
| getNoOutgoingEdges | back to summary |
|---|---|
| public List Get the list of nodes without outgoing edges. A node without outgoing edges is a node that is not a tail of any of the edges in the graph. The returned list is ordered by the indexes of the nodes in the node container of this graph.
| |
| getNoOutgoingEdges | back to summary |
|---|---|
| pack-priv static IntStream getNoOutgoingEdges(BinaryMatrix edgeMatrix) | |
| getOutgoingEdges | back to summary |
|---|---|
| pack-priv static Stream | |
| getTailsOf | back to summary |
|---|---|
| public List Gets the list of nodes that are tails of the edges sharing the same head, which is the given node. The returned list is ordered by the indexes of the nodes in the node container of this graph. | |
| hashCode | back to summary |
|---|---|
| public final int hashCode() Implements abstract java. Doc from java. Returns a hash code value for the record.
Obeys the general contract of | |
| isCyclic | back to summary |
|---|---|
| private static boolean isCyclic(BinaryMatrix edgeMatrix, Consumer<Integer> topologicalOrderAccumulator) | |
| nodes | back to summary |
|---|---|
| public FixedDAG. Record Component getter of nodes.
| |
| topologicalSort | back to summary |
|---|---|
| public List Returns topologically ordered nodes of this graph. For every directed edge ("tail", "head") from "tail" to "head", "tail" comes before "head".
| |
| toString | back to summary |
|---|---|
| public final String toString() Implements abstract java. Doc from java. Returns a string representation of the record.
In accordance with the general contract of In addition to this general contract, record classes must further participate in the invariant that any two records which are equal must produce equal strings. This invariant is necessarily relaxed in the rare case where corresponding equal component values might fail to produce equal strings for themselves. | |
| traverseNodes | back to summary |
|---|---|
| pack-priv static void traverseNodes(int nodeIndex, BinaryMatrix edgeMatrix, boolean heads, Function<Integer, Boolean> nodeAccumulator) | |
| Modifier and Type | Field and Description |
|---|---|
| private final List | |
| private final List |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public FixedDAG. | |
| public FixedDAG. | |
| public FixedDAG. | |
| public FixedDAG |
| edges | back to summary |
|---|---|
| private final List<DirectedEdge<U>> edges | |
| nodes | back to summary |
|---|---|
| private final List<U> nodes | |
| Builder | back to summary |
|---|---|
| public Builder() | |
| addEdge | back to summary |
|---|---|
| public FixedDAG. | |
| addEdge | back to summary |
|---|---|
| public FixedDAG. | |
| addNode | back to summary |
|---|---|
| public FixedDAG. | |
| create | back to summary |
|---|---|
| public FixedDAG | |
| Modifier and Type | Method and Description |
|---|---|
| public U | |
| public int | |
| public static <V> FixedDAG. | |
| public int |
| get | back to summary |
|---|---|
| public U get(int index) | |
| indexOf | back to summary |
|---|---|
| public int indexOf(U node) | |
| ofList | back to summary |
|---|---|
| public static <V> FixedDAG. | |
| size | back to summary |
|---|---|
| public int size() | |