Search in sources :

Example 1 with OfflineConfiguration

use of org.apache.stanbol.ontologymanager.servicesapi.OfflineConfiguration in project stanbol by apache.

the class TestOntologyRegistry method setup.

/**
 * Sets the registry and ontology network managers, which are immutable across tests.
 */
@BeforeClass
public static void setup() {
    // We use a single Dictionary for storing all configurations.
    final Dictionary<String, Object> config = new Hashtable<String, Object>();
    config.put(OfflineConfiguration.ONTOLOGY_PATHS, new String[] { "/ontologies", "/ontologies/registry" });
    OfflineConfiguration offline = new OfflineConfigurationImpl(config);
    // The registry manager can be updated via calls to createModel()
    regman = new RegistryManagerImpl(offline, new ClerezzaOntologyProvider(new SimpleTcProvider(), offline, Parser.getInstance()), config);
}
Also used : Hashtable(java.util.Hashtable) SimpleTcProvider(org.apache.clerezza.rdf.simple.storage.SimpleTcProvider) RegistryManagerImpl(org.apache.stanbol.ontologymanager.registry.impl.RegistryManagerImpl) OfflineConfigurationImpl(org.apache.stanbol.ontologymanager.core.OfflineConfigurationImpl) OfflineConfiguration(org.apache.stanbol.ontologymanager.servicesapi.OfflineConfiguration) ClerezzaOntologyProvider(org.apache.stanbol.ontologymanager.multiplexer.clerezza.ontology.ClerezzaOntologyProvider) BeforeClass(org.junit.BeforeClass)

Aggregations

Hashtable (java.util.Hashtable)1 SimpleTcProvider (org.apache.clerezza.rdf.simple.storage.SimpleTcProvider)1 OfflineConfigurationImpl (org.apache.stanbol.ontologymanager.core.OfflineConfigurationImpl)1 ClerezzaOntologyProvider (org.apache.stanbol.ontologymanager.multiplexer.clerezza.ontology.ClerezzaOntologyProvider)1 RegistryManagerImpl (org.apache.stanbol.ontologymanager.registry.impl.RegistryManagerImpl)1 OfflineConfiguration (org.apache.stanbol.ontologymanager.servicesapi.OfflineConfiguration)1 BeforeClass (org.junit.BeforeClass)1