+
+ public static boolean isActive(ReadGraph graph, Resource runtimeDiagram, Resource profile, Resource entry) throws DatabaseException {
+ DiagramResource DIA = DiagramResource.getInstance(graph);
+ SimulationResource SIMU = SimulationResource.getInstance(graph);
+ if(graph.isInstanceOf(entry, DIA.ProfileEntry)) {
+ if(graph.isImmutable(profile)) {
+ Resource state = getPossibleProfileActivationState(graph, runtimeDiagram, profile);
+ if(state != null && graph.hasStatement(state, SIMU.IsActive, entry)) return true;
+ } else {
+ if(graph.hasStatement(profile, SIMU.IsActive, entry)) return true;
+ }
+ }
+ return false;
+ }
+