public class Rio extends Object
| Constructor and Description |
|---|
Rio() |
| Modifier and Type | Method and Description |
|---|---|
static RDFParser |
createParser(RDFFormat format)
Convenience methods for creating RDFParser objects.
|
static RDFParser |
createParser(RDFFormat format,
ValueFactory valueFactory)
Convenience methods for creating RDFParser objects that use the specified
ValueFactory to create RDF model objects.
|
static RDFWriter |
createWriter(RDFFormat format,
OutputStream out)
Convenience methods for creating RDFWriter objects.
|
static RDFWriter |
createWriter(RDFFormat format,
Writer writer)
Convenience methods for creating RDFWriter objects.
|
static RDFFormat |
getParserFormatForFileName(String fileName)
Tries to match the extension of a file name against the list of RDF
formats that can be parsed.
|
static RDFFormat |
getParserFormatForFileName(String fileName,
RDFFormat fallback)
Tries to match the extension of a file name against the list of RDF
formats that can be parsed.
|
static RDFFormat |
getParserFormatForMIMEType(String mimeType)
Tries to match a MIME type against the list of RDF formats that can be
parsed.
|
static RDFFormat |
getParserFormatForMIMEType(String mimeType,
RDFFormat fallback)
Tries to match a MIME type against the list of RDF formats that can be
parsed.
|
static RDFFormat |
getWriterFormatForFileName(String fileName)
Tries to match the extension of a file name against the list of RDF
formats that can be written.
|
static RDFFormat |
getWriterFormatForFileName(String fileName,
RDFFormat fallback)
Tries to match the extension of a file name against the list of RDF
formats that can be written.
|
static RDFFormat |
getWriterFormatForMIMEType(String mimeType)
Tries to match a MIME type against the list of RDF formats that can be
written.
|
static RDFFormat |
getWriterFormatForMIMEType(String mimeType,
RDFFormat fallback)
Tries to match a MIME type against the list of RDF formats that can be
written.
|
static void |
main(String[] args) |
public static RDFFormat getParserFormatForMIMEType(String mimeType)
mimeType - A MIME type, e.g. "application/rdf+xml".getParserFormatForMIMEType(String, RDFFormat)public static RDFFormat getParserFormatForMIMEType(String mimeType, RDFFormat fallback)
FileFormat.matchMIMEType(String, Iterable) with the specified MIME
type, the keys of RDFParserRegistry.getInstance() and the fallback
format as parameters.mimeType - A MIME type, e.g. "application/rdf+xml".fallback - The format that will be returned if no match was found.public static RDFFormat getParserFormatForFileName(String fileName)
fileName - A file name.getParserFormatForFileName(String, RDFFormat)public static RDFFormat getParserFormatForFileName(String fileName, RDFFormat fallback)
FileFormat.matchFileName(String, Iterable, info.aduna.lang.FileFormat)
with the specified MIME type, the keys of
RDFParserRegistry.getInstance() and the fallback format as
parameters.fileName - A file name.fallback - The format that will be returned if no match was found.public static RDFFormat getWriterFormatForMIMEType(String mimeType)
mimeType - A MIME type, e.g. "application/rdf+xml".getWriterFormatForMIMEType(String, RDFFormat)public static RDFFormat getWriterFormatForMIMEType(String mimeType, RDFFormat fallback)
FileFormat.matchMIMEType(String, Iterable, info.aduna.lang.FileFormat)
with the specified MIME type, the keys of
RDFWriterRegistry.getInstance() and the fallback format as
parameters.mimeType - A MIME type, e.g. "application/rdf+xml".fallback - The format that will be returned if no match was found.public static RDFFormat getWriterFormatForFileName(String fileName)
fileName - A file name.getWriterFormatForFileName(String, RDFFormat)public static RDFFormat getWriterFormatForFileName(String fileName, RDFFormat fallback)
FileFormat.matchFileName(String, Iterable, info.aduna.lang.FileFormat)
with the specified MIME type, the keys of
RDFWriterRegistry.getInstance() and the fallback format as
parameters.fileName - A file name.fallback - The format that will be returned if no match was found.public static RDFParser createParser(RDFFormat format) throws UnsupportedRDFormatException
RDFParserRegistry.getInstance() to get a
factory for the specified format and uses this factory to create the
appropriate parser.UnsupportedRDFormatException - If no parser is available for the specified RDF format.public static RDFParser createParser(RDFFormat format, ValueFactory valueFactory) throws UnsupportedRDFormatException
UnsupportedRDFormatException - If no parser is available for the specified RDF format.createParser(RDFFormat),
RDFParser.setValueFactory(ValueFactory)public static RDFWriter createWriter(RDFFormat format, OutputStream out) throws UnsupportedRDFormatException
RDFWriterRegistry.getInstance() to get a
factory for the specified format and uses this factory to create the
appropriate writer.UnsupportedRDFormatException - If no writer is available for the specified RDF format.public static RDFWriter createWriter(RDFFormat format, Writer writer) throws UnsupportedRDFormatException
RDFWriterRegistry.getInstance() to get a
factory for the specified format and uses this factory to create the
appropriate writer.UnsupportedRDFormatException - If no writer is available for the specified RDF format.public static void main(String[] args) throws IOException, RDFParseException, RDFHandlerException, UnsupportedRDFormatException
Copyright © 2001-2013 Aduna. All Rights Reserved.