|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.ontopia.topicmaps.xml.CanonicalTopicMapWriter
public class CanonicalTopicMapWriter
PUBLIC: A topic map writer that writes topic maps out to Ontopia's Canonical XTM topic map format. This format is generally used for testing and not for other purposes.
Note: this is the format defined in an Ontopia technical report, not the upcoming standard format. For new code, please use the standard format.
Nested Class Summary | |
---|---|
class |
CanonicalTopicMapWriter.CanonicalXTMPrinter
|
Field Summary | |
---|---|
protected LocatorIF |
baseloc
|
protected org.xml.sax.DocumentHandler |
out
|
protected java.io.OutputStream |
stream
|
Constructor Summary | |
---|---|
CanonicalTopicMapWriter(java.io.File file)
Creates a topic map writer bound to the file given in the arguments. |
|
CanonicalTopicMapWriter(java.io.OutputStream stream)
Creates a topic map writer bound to the output stream given in the arguments. |
|
CanonicalTopicMapWriter(java.lang.String filename)
Creates a topic map writer bound to the file given in the arguments. |
Method Summary | |
---|---|
void |
export(TopicMapIF topicmap,
org.xml.sax.DocumentHandler dh)
PUBLIC: Exports the topic map to the given DocumentHandler. |
LocatorIF |
getBaseLocator()
INTERNAL: Gets the base locator used to resolve relative locators. |
void |
setBaseLocator(LocatorIF baseloc)
INTERNAL: Sets the base locator used to resolve relative locators. |
void |
write(TopicMapIF topicmap)
PUBLIC: Writes the given topic map to an implicit implementation dependent destination. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected org.xml.sax.DocumentHandler out
protected java.io.OutputStream stream
protected LocatorIF baseloc
Constructor Detail |
---|
public CanonicalTopicMapWriter(java.lang.String filename) throws java.io.IOException
filename
- The name of the file to which the topic map is to
be written.
java.io.IOException
public CanonicalTopicMapWriter(java.io.File file) throws java.io.IOException
file
- The file object to which the topic map is to be written.
java.io.IOException
public CanonicalTopicMapWriter(java.io.OutputStream stream)
stream
- The output stream to which the topic map is to be
written.Method Detail |
---|
public void write(TopicMapIF topicmap) throws java.io.IOException
TopicMapWriterIF
write
in interface TopicMapWriterIF
topicmap
- The topic map to be exported/written;
an object implementing TopicMapIF
java.io.IOException
- Thrown if writing the topic map fails.public LocatorIF getBaseLocator()
public void setBaseLocator(LocatorIF baseloc)
public void export(TopicMapIF topicmap, org.xml.sax.DocumentHandler dh) throws java.io.IOException, org.xml.sax.SAXException
java.io.IOException
org.xml.sax.SAXException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |