Package org.wikidata.wdtk.rdf
Class RdfConverter
java.lang.Object
org.wikidata.wdtk.rdf.AbstractRdfConverter
org.wikidata.wdtk.rdf.RdfConverter
-
Nested Class Summary
Nested classes/interfaces inherited from class org.wikidata.wdtk.rdf.AbstractRdfConverter
AbstractRdfConverter.TermKind
-
Constructor Summary
ConstructorDescriptionRdfConverter
(RdfWriter rdfWriter, Sites sites, PropertyRegister propertyRegister) -
Method Summary
Modifier and TypeMethodDescriptionint
getTasks()
Returns the tasks that should be performed during export.void
setTasks
(int tasks) Sets the tasks that should be performed during export.void
writeFullStatement
(Statement statement, boolean best) void
writeInterPropertyLinks
(PropertyDocument document) Writes triples which connect properties with their corresponding rdf properties for statements, simple statements, qualifiers, reference attributes and values.void
writeItemDocument
(ItemDocument document) void
void
writePropertyDatatype
(PropertyDocument document) void
writePropertyDocument
(PropertyDocument document) void
writeSimpleStatement
(Statement statement) void
writeSiteLinks
(org.eclipse.rdf4j.model.Resource subject, Map<String, SiteLink> siteLinks) void
writeTermTriples
(org.eclipse.rdf4j.model.Resource subject, AbstractRdfConverter.TermKind kind, Collection<MonolingualTextValue> terms) Methods inherited from class org.wikidata.wdtk.rdf.AbstractRdfConverter
finishDocument, getDatatypeIri, getMonolingualTextValueLiteral, writeBasicDeclarations, writeClaim, writeDocumentTerms, writeDocumentType, writeNamespaceDeclarations, writeReferences, writeStatement, writeStatementRankTriple, writeStatements
-
Constructor Details
-
RdfConverter
-
-
Method Details
-
setTasks
public void setTasks(int tasks) Sets the tasks that should be performed during export. The value should be a combination of flags such asRdfSerializer.TASK_STATEMENTS
.- Parameters:
tasks
- the tasks to be performed
-
getTasks
public int getTasks()Returns the tasks that should be performed during export. The value should be a combination of flags such asRdfSerializer.TASK_STATEMENTS
.- Returns:
- tasks to be performed
-
writeTermTriples
public void writeTermTriples(org.eclipse.rdf4j.model.Resource subject, AbstractRdfConverter.TermKind kind, Collection<MonolingualTextValue> terms) throws org.eclipse.rdf4j.rio.RDFHandlerException - Overrides:
writeTermTriples
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writeSiteLinks
public void writeSiteLinks(org.eclipse.rdf4j.model.Resource subject, Map<String, SiteLink> siteLinks) throws org.eclipse.rdf4j.rio.RDFHandlerException- Overrides:
writeSiteLinks
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writePropertyDatatype
- Overrides:
writePropertyDatatype
in classAbstractRdfConverter
-
writeInterPropertyLinks
public void writeInterPropertyLinks(PropertyDocument document) throws org.eclipse.rdf4j.rio.RDFHandlerException Description copied from class:AbstractRdfConverter
Writes triples which connect properties with their corresponding rdf properties for statements, simple statements, qualifiers, reference attributes and values.- Overrides:
writeInterPropertyLinks
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writeSimpleStatement
- Overrides:
writeSimpleStatement
in classAbstractRdfConverter
-
writeFullStatement
public void writeFullStatement(Statement statement, boolean best) throws org.eclipse.rdf4j.rio.RDFHandlerException - Overrides:
writeFullStatement
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writeItemDocument
public void writeItemDocument(ItemDocument document) throws org.eclipse.rdf4j.rio.RDFHandlerException - Overrides:
writeItemDocument
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writePropertyDocument
public void writePropertyDocument(PropertyDocument document) throws org.eclipse.rdf4j.rio.RDFHandlerException - Overrides:
writePropertyDocument
in classAbstractRdfConverter
- Throws:
org.eclipse.rdf4j.rio.RDFHandlerException
-
writeOWLDeclarations
public void writeOWLDeclarations()- Overrides:
writeOWLDeclarations
in classAbstractRdfConverter
-