53 |
public static void main(String[] args) throws RDFException, IOException { |
public static void main(String[] args) throws RDFException, IOException { |
54 |
final Model model = load(args[0]); |
final Model model = load(args[0]); |
55 |
final Statement stmt = model.listStatements().next(); |
final Statement stmt = model.listStatements().next(); |
|
final Cursor cursor = new Cursor(stmt.getSubject(), stmt.getObject()); |
|
56 |
final GraphicsAPI api = GraphicsAPI.getInstance(); |
final GraphicsAPI api = GraphicsAPI.getInstance(); |
57 |
|
|
58 |
final Comparator cmp = new Comparator() { |
final Comparator order = new Comparator() { |
59 |
public int compare(Object o1, Object o2) { |
public int compare(Object o1, Object o2) { |
60 |
return o1.hashCode() - o2.hashCode(); |
return o1.hashCode() - o2.hashCode(); |
61 |
} |
} |
62 |
}; |
}; |
63 |
|
final Cursor cursor = |
64 |
|
new Cursor(order, stmt.getSubject(), stmt.getObject()); |
65 |
|
|
66 |
final Vob bg = new RectBgVob(); |
final Vob bg = new RectBgVob(); |
67 |
final TextStyle style = api.getTextStyle("Serif", 0, 12); |
final TextStyle style = api.getTextStyle("Serif", 0, 12); |
68 |
final NodeView nodeView = new NodeView() { |
final NodeView nodeView = new NodeView() { |
78 |
} |
} |
79 |
public VobScene generate() { |
public VobScene generate() { |
80 |
VobScene sc = this.screen.window.createVobScene(); |
VobScene sc = this.screen.window.createVobScene(); |
81 |
SimpleView sv = new SimpleView(cmp, nodeView); |
SimpleView sv = new SimpleView(nodeView); |
82 |
sc.map.put(new SolidBgVob(java.awt.Color.white), 0); |
sc.map.put(new SolidBgVob(java.awt.Color.white), 0); |
83 |
sv.render(sc, 0, cursor); |
sv.render(sc, 0, cursor); |
84 |
return sc; |
return sc; |