66 |
public static Graph toGraph(Model m) { |
public static Graph toGraph(Model m) { |
67 |
try { |
try { |
68 |
Graph g = new HashGraph(); |
Graph g = new HashGraph(); |
69 |
for(StmtIterator i=m.listStatements(); i.hasNext(); i.next()) { |
StmtIterator i=m.listStatements(); |
70 |
|
while (i.hasNext()) { |
71 |
Statement s = i.next(); |
Statement s = i.next(); |
72 |
Object sub = Nodes.get(s.getSubject().toString()); |
Object sub = Nodes.get(s.getSubject().toString()); |
73 |
Object pred = Nodes.get(s.getPredicate().toString()); |
Object pred = Nodes.get(s.getPredicate().toString()); |