public class OWLShuntGraph extends Object
OWLShuntNode
and OWLShuntEdge
.Modifier and Type | Field and Description |
---|---|
Set<OWLShuntEdge> |
edges |
String |
id |
Set<OWLShuntNode> |
nodes |
Constructor and Description |
---|
OWLShuntGraph()
Empty constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
addEdge(OWLShuntEdge e)
Simply "add" an edge to the graph.
|
boolean |
addNode(OWLShuntNode n)
Simply "add" a node to the graph.
|
Set<String> |
getChildren(String nodeID)
Return the set of children of a node as IDs.
|
Set<String> |
getLeaves()
Return the set of graph leaves (no children) as IDs.
|
Set<String> |
getParents(String nodeID)
Return the set of parents of a node as IDs.
|
Set<String> |
getRoots()
Return the set of graph roots (no parents) as IDs.
|
boolean |
hasEdge(OWLShuntEdge e)
Check to see if an edge is in the graph.
|
boolean |
hasNode(OWLShuntNode n)
Check to see if a node is in the graph.
|
Iterator<String> |
iteratorDF()
Get a depth-first iterator for the graph.
|
String |
toJSON() |
String |
unsafeToJSON() |
public String id
public Set<OWLShuntNode> nodes
public Set<OWLShuntEdge> edges
public boolean hasNode(OWLShuntNode n)
n
- public boolean hasEdge(OWLShuntEdge e)
e
- public boolean addNode(OWLShuntNode n)
n
- public boolean addEdge(OWLShuntEdge e)
e
- public Set<String> getParents(String nodeID)
nodeID
- public Set<String> getChildren(String nodeID)
nodeID
- public Set<String> getRoots()
public Set<String> getLeaves()
public Iterator<String> iteratorDF()
public String toJSON()
public String unsafeToJSON()
Copyright © 2010–2015. All rights reserved.