public abstract class ModelDocument extends Object
| Modifier and Type | Field and Description |
|---|---|
static int |
_trace_level
The _trace_level.
|
static String |
COMMENT
The Constant COMMENT.
|
static int |
DEBUG
The Constant VERBOSE.
|
static String |
DESCRIPTION
The Constant DESCRIPTION.
|
static String |
DOMAIN
The Constant DOMAIN.
|
static int |
INFO
The Constant VERBOSE.
|
static String |
LABEL
The Constant LABEL.
|
static String |
MEMBER
The Constant MEMBER.
|
protected String |
modelURI
The model uri.
|
static int |
NONE
The Constant VERBOSE.
|
static String |
RANGE
The Constant RANGE.
|
static String |
SUB_CLASS_OF
The Constant SUB_CLASS_OF.
|
static String |
SUB_PROPERTY_OF
The Constant SUB_PROPERTY_OF.
|
static int |
VERBOSE
The Constant VERBOSE.
|
| Modifier | Constructor and Description |
|---|---|
protected |
ModelDocument(String modelURI)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected Map<String,String> |
_load(Map<String,String> targetMap,
Map<String,String> sourceMap,
String label)
Utility method for property Map management.
|
Map<String,String> |
classDetails(String termURI,
String language)
Method to document rdfs:Class resource specific details.
|
Map<String,String> |
classes()
Classes.
|
Map<String,String> |
collections()
Method to compile and return a catalog Map of collections with list of
members.
|
void |
dumpModel()
Default is to dump the model in N3 format on stdout.
|
void |
dumpModel(OutputStream output)
Default is to dump the model in N3 format on stdout.
|
void |
dumpModel(OutputStream out,
String format)
Dump model.
|
void |
dumpModel(String format)
Dump model.
|
void |
dumpModel(String fileName,
String format)
Dump model.
|
void |
dumpSchema()
Method dumpSchema with default language.
|
void |
dumpSchema(String language)
Dump schema.
|
static ModelDocument |
lookup(String uri)
Method with default language.
|
static ModelDocument |
lookup(String uri,
String language)
Lookup.
|
Map<String,String> |
members(String collectionURI)
Method to return the members of a skos:Collection, as complete URI's.
|
Parser |
parser()
Parser.
|
Map<String,String> |
properties()
Properties.
|
Map<String,String> |
propertyDetails(String termURI,
String language)
Method to document rdfs:Class resource specific details.
|
protected void |
setLanguage(String language)
Method.
|
Map<String,String> |
subjectsOfType(String typeURI)
Subjects of type.
|
static void |
trace(int level)
Trace.
|
protected ModelDocument |
translatedModel()
Method that returns the ModelDocument associated with the current
language translation associated with the core RDF model (i.e.
|
String |
URI()
Uri.
|
public static final int NONE
public static final int INFO
public static final int DEBUG
public static final int VERBOSE
public static int _trace_level
public static final String LABEL
public static final String COMMENT
public static final String DESCRIPTION
public static final String SUB_CLASS_OF
public static final String SUB_PROPERTY_OF
public static final String MEMBER
public static final String DOMAIN
public static final String RANGE
protected String modelURI
protected ModelDocument(String modelURI) throws IOException, ModelException
modelURI - of RDF document to loadIOException - - if model file cannot be accessed ModelException -
if invalid modelURI parameter specifiedModelException - the model exceptionpublic static void trace(int level)
level - the levelpublic String URI()
public Parser parser()
protected void setLanguage(String language) throws IOException, ModelException
language - the new languageIOException - Signals that an I/O exception has occurred.ModelException - the model exceptionprotected ModelDocument translatedModel()
public void dumpModel(OutputStream out, String format)
out - the outformat - to output filepublic void dumpModel(String fileName, String format)
fileName - the file nameformat - to output filepublic void dumpModel(String format)
format - to stdoutpublic void dumpModel()
public void dumpModel(OutputStream output)
output - the outputpublic Map<String,String> subjectsOfType(String typeURI) throws RDFParserException
typeURI - the type uriRDFParserException - the RDF parser exceptionpublic Map<String,String> classes() throws RDFParserException
RDFParserException - the RDF parser exceptionpublic Map<String,String> properties() throws RDFParserException
RDFParserException - the RDF parser exceptionpublic Map<String,String> members(String collectionURI) throws RDFParserException
collectionURI - the collection uriRDFParserException - the RDF parser exceptionpublic Map<String,String> collections() throws RDFParserException
RDFParserException - the RDF parser exceptionprotected Map<String,String> _load(Map<String,String> targetMap, Map<String,String> sourceMap, String label)
targetMap - the target mapsourceMap - the source maplabel - the labelpublic Map<String,String> classDetails(String termURI, String language) throws RDFParserException
termURI - the term urilanguage - the languageRDFParserException - the RDF parser exceptionpublic Map<String,String> propertyDetails(String termURI, String language) throws RDFParserException
termURI - the term urilanguage - the languageRDFParserException - the RDF parser exceptionpublic void dumpSchema(String language)
language - the languagepublic void dumpSchema()
public static ModelDocument lookup(String uri, String language) throws RDFParserException
uri - the urilanguage - the languageRDFParserException - the RDF parser exceptionpublic static ModelDocument lookup(String uri) throws RDFParserException
uri - the uriRDFParserException - the RDF parser exceptionCopyright © 2016. All rights reserved.