public class RdfValueFactory extends Object implements org.apache.stanbol.entityhub.servicesapi.model.ValueFactory
| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
log |
protected org.openrdf.model.ValueFactory |
sesameFactory |
| Constructor and Description |
|---|
RdfValueFactory(org.openrdf.model.Model model,
org.openrdf.model.ValueFactory sesameFactory)
Create a RdfValueFactory that does use the same
Model for all
created Representations. |
| Modifier and Type | Method and Description |
|---|---|
RdfRepresentation |
createRdfRepresentation(org.openrdf.model.URI subject)
Creates a
RdfRepresentation for the parsed URI |
org.apache.stanbol.entityhub.servicesapi.model.Reference |
createReference(Object value) |
org.apache.stanbol.entityhub.servicesapi.model.Representation |
createRepresentation(String id) |
org.apache.stanbol.entityhub.servicesapi.model.Text |
createText(Object value) |
org.apache.stanbol.entityhub.servicesapi.model.Text |
createText(String text,
String language) |
static RdfValueFactory |
getInstance()
The default instance of this Factory.
|
org.openrdf.model.ValueFactory |
getSesameFactory()
Getter for the Sesame
ValueFactory used by
this Entityhub ValueFactory. |
RdfRepresentation |
toRdfRepresentation(org.apache.stanbol.entityhub.servicesapi.model.Representation representation)
|
protected final org.slf4j.Logger log
protected final org.openrdf.model.ValueFactory sesameFactory
public RdfValueFactory(org.openrdf.model.Model model,
org.openrdf.model.ValueFactory sesameFactory)
Model for all
created Representations.model - the model to usesesameFactory - the Sesame ValueFactory or null to use
the defaultpublic static RdfValueFactory getInstance()
public org.apache.stanbol.entityhub.servicesapi.model.Reference createReference(Object value) throws org.apache.stanbol.entityhub.servicesapi.model.UnsupportedTypeException, IllegalArgumentException
createReference in interface org.apache.stanbol.entityhub.servicesapi.model.ValueFactoryorg.apache.stanbol.entityhub.servicesapi.model.UnsupportedTypeExceptionIllegalArgumentExceptionpublic org.apache.stanbol.entityhub.servicesapi.model.Representation createRepresentation(String id) throws IllegalArgumentException
createRepresentation in interface org.apache.stanbol.entityhub.servicesapi.model.ValueFactoryIllegalArgumentExceptionpublic RdfRepresentation createRdfRepresentation(org.openrdf.model.URI subject)
RdfRepresentation for the parsed URIsubject - the URIRdfRepresentationpublic org.apache.stanbol.entityhub.servicesapi.model.Text createText(Object value) throws org.apache.stanbol.entityhub.servicesapi.model.UnsupportedTypeException, IllegalArgumentException
createText in interface org.apache.stanbol.entityhub.servicesapi.model.ValueFactoryorg.apache.stanbol.entityhub.servicesapi.model.UnsupportedTypeExceptionIllegalArgumentExceptionpublic org.apache.stanbol.entityhub.servicesapi.model.Text createText(String text, String language) throws IllegalArgumentException
createText in interface org.apache.stanbol.entityhub.servicesapi.model.ValueFactoryIllegalArgumentExceptionpublic org.openrdf.model.ValueFactory getSesameFactory()
ValueFactory used by
this Entityhub ValueFactory.public RdfRepresentation toRdfRepresentation(org.apache.stanbol.entityhub.servicesapi.model.Representation representation)
representation - the representationRdfRepresentationCopyright © 2013-2014 The Apache Software Foundation. All Rights Reserved.