com.hp.hpl.mesa.rdf.jena.common
Class RDFXMLWriter
java.lang.Object
|
+--com.hp.hpl.mesa.rdf.jena.common.RDFXMLWriter
- All Implemented Interfaces:
- RDFWriter
- public class RDFXMLWriter
- extends java.lang.Object
- implements RDFWriter
Writes out an XML serialization of a model.
- Version:
- Release='$Name: $' Revision='$Revision: 1.5 $' Date='$Date: 2002/01/09 16:55:34 $'
- Author:
- bwm
Method Summary |
RDFErrorHandler |
setErrorHandler(RDFErrorHandler errHandler)
Set an error handler. |
void |
setNsPrefix(java.lang.String prefix,
java.lang.String ns)
Set the the namespace prefix to be used for a particular namespace. |
java.lang.Object |
setProperty(java.lang.String propName,
java.lang.Object propValue)
Sets the XML base if required. |
void |
write(Model model,
java.io.Writer writer,
java.lang.String base)
Write out an XML serialization of a model. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
RDFXMLWriter
public RDFXMLWriter()
write
public void write(Model model,
java.io.Writer writer,
java.lang.String base)
throws RDFException
- Write out an XML serialization of a model.
- Specified by:
write
in interface RDFWriter
- Parameters:
model
- the model to be serializedwriter
- the PrintWriter to receive the serialization- Throws:
IOException
- if an io error occursRDFException
- if any other exception occurs
setNsPrefix
public void setNsPrefix(java.lang.String prefix,
java.lang.String ns)
- Description copied from interface:
RDFWriter
- Set the the namespace prefix to be used for a particular namespace.
- Specified by:
setNsPrefix
in interface RDFWriter
- Following copied from interface:
com.hp.hpl.mesa.rdf.jena.model.RDFWriter
- Parameters:
prefix
- the prefix to be usedns
- the namespace
setErrorHandler
public RDFErrorHandler setErrorHandler(RDFErrorHandler errHandler)
- Description copied from interface:
RDFWriter
- Set an error handler.
- Specified by:
setErrorHandler
in interface RDFWriter
- Following copied from interface:
com.hp.hpl.mesa.rdf.jena.model.RDFWriter
- Parameters:
errHandler
- The new error handler to be used.- Returns:
- the old error handler
setProperty
public java.lang.Object setProperty(java.lang.String propName,
java.lang.Object propValue)
throws RDFException
- Sets the XML base if required. Xmlbase is assumed to be a string.
- Specified by:
setProperty
in interface RDFWriter
- Parameters:
propName
- Must be "xmlbase"propValue
- The string (URI) to set for the xmlbase object.- Returns:
- the old value for this property, or
null
if no value was set.
Copyright © 2001 Hewlett-Packard. All Rights Reserved.