[TASK] Fire CarTireWearEvent only when car is moving.

This commit is contained in:
Jan Philipp Timme 2016-10-10 15:48:13 +02:00
parent d3b47eb9ce
commit 19ca2bd989

View File

@ -399,6 +399,7 @@ public class RentACarSimulation implements Runnable {
+ "FROM <"+RentACarSimulation.DOMAIN_KNOWLEDGE_GRAPH_IRI+"> "
+ "WHERE { "
+ " ?e rdf:type car:CarStatusEvent . "
+ " ?e car:speed ?speed . "
+ " ?e car:relatedCar ?car . "
+ " ?car car:isCarModel ?carModel . "
+ " ?carModel car:minimumTirePressure ?minTirePressure . "
@ -406,6 +407,7 @@ public class RentACarSimulation implements Runnable {
+ " ?e car:tirePressure2 ?tpress2 . "
+ " ?e car:tirePressure3 ?tpress3 . "
+ " ?e car:tirePressure4 ?tpress4 . "
+ " FILTER(?speed > 0) "
+ " FILTER(?tpress1 < ?minTirePressure || ?tpress2 < ?minTirePressure || ?tpress3 < ?minTirePressure || ?tpress4 < ?minTirePressure) "
+ "}";
QueryContainer queryContainer = new QueryContainer("getTireWear", query, true);