org.ontoware.rdf2go
Interface ModelFactory


public interface ModelFactory

RDF2Go adapters have toi implement this interface to be able to create Models and ModelSets. Property keys are defined in this interface (Reasoning, Storage).

Author:
voelkel

Field Summary
static java.lang.String REASONING
          The Property key to indicate the Reasoning state in the properties.
static java.lang.String STORAGE
          The Property key to indicate where to store the model or modelset.
static java.lang.String STORAGE_VALUE_MEMORY
           
 
Method Summary
 Model createModel()
          Create a default in-memory ModelSet with no inferencing.
 Model createModel(java.util.Properties p)
          Create a Model configured by the given properties.
 Model createModel(Reasoning reasoning)
          Create a new Model with inferencing.
 Model createModel(URI contextURI)
          Create a default in-memory ModelSet with no inferencing and the given context URI.
 ModelSet createModelSet()
          create a default in-memory ModelSet with no inferencing.
 ModelSet createModelSet(java.util.Properties p)
          Create a ModelSet configured by the given properties.
 ModelSet createModelSet(Reasoning reasoning)
          Create a default in-memory ModelSet with given inferencing.
 

Field Detail

REASONING

static final java.lang.String REASONING
The Property key to indicate the Reasoning state in the properties. Legal values are:

See Also:
Constant Field Values

STORAGE

static final java.lang.String STORAGE
The Property key to indicate where to store the model or modelset. Legal values are:

See Also:
Constant Field Values

STORAGE_VALUE_MEMORY

static final java.lang.String STORAGE_VALUE_MEMORY
See Also:
Constant Field Values
Method Detail

createModel

Model createModel()
                  throws ModelRuntimeException
Create a default in-memory ModelSet with no inferencing.

Returns:
a Model implementation.
Throws:
ModelRuntimeException - if the adapter could not create the model

createModel

Model createModel(URI contextURI)
                  throws ModelRuntimeException
Create a default in-memory ModelSet with no inferencing and the given context URI. All statements added to this model will have this context as the context of each statement.

Returns:
a Model implementation bound to the given context URI.
Throws:
ModelRuntimeException - if the adapter could not create the model

createModel

Model createModel(Reasoning reasoning)
                  throws ReasoningNotSupportedException,
                         ModelRuntimeException
Create a new Model with inferencing. Type of reasoning is passed.

Parameters:
reasoning - the type of reasoning that is needed
Returns:
a model with reasoning support
Throws:
ModelRuntimeException - if the adapter could not create the Model
ReasoningNotSupportedException - if the passed kind of reasoning is not supported.

createModel

Model createModel(java.util.Properties p)
                  throws ModelRuntimeException
Create a Model configured by the given properties. You have to look at the adapter documentation to see which properties do what.

Parameters:
properties - configures the to-be-created Model
Returns:
the created Model
Throws:
ModelRuntimeException - if the adapter could not create the Model
ReasoningNotSupportedException - if the passed kind of reasoning is not supported.
ModelRuntimeException

createModelSet

ModelSet createModelSet()
                        throws ModelRuntimeException
create a default in-memory ModelSet with no inferencing.

Returns:
a ModelSet implementation.
Throws:
NotImplementedException - a RuntimeException if this method is not implemented. Should not happen.
ModelRuntimeException

createModelSet

ModelSet createModelSet(Reasoning reasoning)
                        throws ReasoningNotSupportedException,
                               ModelRuntimeException
Create a default in-memory ModelSet with given inferencing. Type of reasoning is passed.

Parameters:
reasoning - the type of reasoning that is needed
Returns:
the created ModelSet
Throws:
ModelRuntimeException
ReasoningNotSupportedException - if the passed kind of reasoning is not supported.
ModelRuntimeException - if the adapter could not create the model

createModelSet

ModelSet createModelSet(java.util.Properties p)
                        throws ModelRuntimeException
Create a ModelSet configured by the given properties. You have to look at the adapter documentation to see which properties do what.

Parameters:
properties - - configures the model creation
Returns:
the created ModelSet
Throws:
ModelRuntimeException - if the adapter could not create the Model
ReasoningNotSupportedException - if the passed kind of reasoning is not supported.


Copyright © 2005-2008 FZI - Forschungszentrum Informatik | Karlsruhe | Germany. All Rights Reserved.