Node<DataT,NodeT> Class
- java.
lang. Object - com.
azure. resourcemanager. resources. fluentcore. dag. Node<DataT,NodeT>
- com.
Type Parameters
- DataT
the type of the data stored in the node
- NodeT
the type of the node
public class Node<DataT,NodeT>
Type represents a node in a Graph<DataT,NodeT>.
Constructor Summary
Constructor | Description |
---|---|
Node(String key, DataT data) |
Creates a graph node. |
Method Summary
Modifier and Type | Method and Description |
---|---|
void | addChild(String childKey) |
List<String> | children() |
DataT | data() |
boolean | hasChildren() |
String | key() |
Graph<DataT,NodeT> | owner() |
void | removeChild(String childKey) |
void |
setOwner(Graph<DataT,NodeT> ownerGraph)
Sets reference to the graph owning this node. |
Methods inherited from java.lang.Object
Constructor Details
Node
public Node(String key, DataT data)
Creates a graph node.
Parameters:
Method Details
addChild
public void addChild(String childKey)
Parameters:
children
public List
Returns:
data
public DataT data()
Returns:
hasChildren
public boolean hasChildren()
Returns:
key
public String key()
Returns:
owner
public Graph
Returns:
removeChild
public void removeChild(String childKey)
Parameters:
setOwner
public void setOwner(Graph
Sets reference to the graph owning this node.
Parameters:
Applies to
Azure SDK for Java