|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mulgara.mrg.writer.AbstractGraphWriter
public class AbstractGraphWriter
| Field Summary | |
|---|---|
protected String |
base
The base for the document. |
protected Graph |
graph
The graph to be emitted. |
protected org.mulgara.mrg.writer.PrefixGenerator |
prefixGen
A generator for creating namespace prefix names |
protected Map<String,String> |
rns
The registered namespaces to use while emitting the graph, reverse mapped. |
| Constructor Summary | |
|---|---|
AbstractGraphWriter(Graph graph,
URI base)
Create a graph writer with an empty namespace map. |
|
AbstractGraphWriter(Graph graph,
URI base,
Map<String,URI> ns)
Create a graph writer with a specified namespace map. |
|
| Method Summary | |
|---|---|
Map<String,URI> |
getNamespaces()
Gets a mapping of prefixes to their namespaces. |
void |
resetNamespaces()
Clears out the prefix/namespace set. |
void |
scanNamespaces()
Scans the URIs in the graph to find all the namespaces. |
void |
setNamespaces(Map<String,URI> ns)
|
void |
setNamespacesByString(Map<String,String> ns)
|
protected boolean |
testNamespace(String ns)
Tests a potential namespace to see if it is considered to be OK. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected final Graph graph
protected final String base
protected Map<String,String> rns
protected org.mulgara.mrg.writer.PrefixGenerator prefixGen
| Constructor Detail |
|---|
public AbstractGraphWriter(Graph graph,
URI base)
graph - The write to be written.
public AbstractGraphWriter(Graph graph,
URI base,
Map<String,URI> ns)
graph - The write to be written.ns - The namespace map to use. This maps prefixes to namespaces.| Method Detail |
|---|
public void setNamespaces(Map<String,URI> ns)
GraphWriter.setNamespaces(java.util.Map)
public void setNamespacesByString(Map<String,String> ns)
throws URISyntaxException
URISyntaxExceptionGraphWriter.setNamespacesByString(java.util.Map)public void resetNamespaces()
public void scanNamespaces()
public Map<String,URI> getNamespaces()
protected boolean testNamespace(String ns)
ns - The namespace to test.
true iff the namespace can be used in this type of document.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||