From e093469fa94505e2b7b105d59c1d14ef9416ae74 Mon Sep 17 00:00:00 2001 From: Jan Philipp Timme Date: Wed, 5 Oct 2016 19:56:19 +0200 Subject: [PATCH] [TASK] Generic commit. --- .../java/lu/jpt/csparqlproject/SimulationContext.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/lu/jpt/csparqlproject/SimulationContext.java b/src/main/java/lu/jpt/csparqlproject/SimulationContext.java index 239dd62..58bedd5 100644 --- a/src/main/java/lu/jpt/csparqlproject/SimulationContext.java +++ b/src/main/java/lu/jpt/csparqlproject/SimulationContext.java @@ -8,6 +8,7 @@ import org.slf4j.Logger; import org.slf4j.LoggerFactory; import eu.larkc.csparql.cep.api.RdfStream; +import eu.larkc.csparql.common.utils.CsparqlUtils; import eu.larkc.csparql.core.engine.CsparqlEngine; import eu.larkc.csparql.core.engine.CsparqlEngineImpl; import eu.larkc.csparql.core.engine.CsparqlQueryResultProxy; @@ -22,7 +23,7 @@ import lu.jpt.csparqlproject.util.CsparqlQueryHelper.CsparqlQueryInfo; * which provides the needed event streams is being initialized, and its event streams * are being registered with the engine. * - * Also, the neccessary C-SPARQL queries are fetched from the RentACarSimulation and + * Also, the necessary C-SPARQL queries are fetched from the RentACarSimulation and * also getting registered with the engine. This way, everything you may need to know * about how to use the engine itself lies within here. * @@ -104,7 +105,7 @@ public class SimulationContext { for(CsparqlQueryResultProxy resultProxy : this.queryResultProxies) { this.engine.unregisterQuery(resultProxy.getId()); } - // Unregister all rdf streams from the engine + // Unregister all streams from the engine for(RdfStream eventStream : this.registeredStreams) { this.engine.unregisterStream(eventStream.getIRI()); } @@ -129,14 +130,13 @@ public class SimulationContext { SimulationContext.logger.debug("CWD: " + System.getProperty("user.dir")); SimulationContext.logger.debug("Engine from: " + this.engine.getClass().getProtectionDomain().getCodeSource()); // Load local domain knowledge into its target graph - /* try { engine.putStaticNamedModel("http://example.org/carSimKnowledgeGraph", CsparqlUtils.serializeRDFFile("data/carSimulationABox.rdf")); } catch (Exception e) { SimulationContext.logger.error(e.toString()); SimulationContext.logger.error(e.getStackTrace().toString()); } - */ + // From the C-SPARQL-ReadyToGoPack: // Note: This is how local domain knowledge can be updated during runtime: /* Use a SPARQL Query to update the local knowledge from code instead of using CONSTRUCT within the engine. String updateQuery = "PREFIX : " @@ -195,7 +195,7 @@ public class SimulationContext { /** * Builds a query result observer depending on the given queryName. - * This is useful if a querys result set is larger than usual. + * This is useful if a queries result set is larger than usual. * @param queryName * @return Observer for query result */