import org.simantics.db.layer0.variable.Variable;
import org.simantics.db.layer0.variable.Variables;
import org.simantics.diagram.stubs.DiagramResource;
+import org.simantics.district.network.ontology.DistrictNetworkResource;
import org.simantics.district.region.ontology.DiagramRegionsResource;
import org.simantics.district.selection.ElementSelector.AggregateCondition.Type;
import org.simantics.layer0.Layer0;
static StructuralResource2 STR;
static ModelingResources MOD;
static DiagramResource DIA;
+ static DistrictNetworkResource DN;
ElementSelector(ReadGraph graph, Resource resource) throws DatabaseException {
super();
STR = StructuralResource2.getInstance(graph);
MOD = ModelingResources.getInstance(graph);
DIA = DiagramResource.getInstance(graph);
+ DN = DistrictNetworkResource.getInstance(graph);
this.resource = resource;
this.count = -1;
if (value != null)
return value.doubleValue();
}
+
+ // No property found - try possible mapped element property as well
+ Resource mappedElement = graph.getPossibleObject(element, DN.MappedComponent);
+ if (mappedElement != null)
+ return getPropertyValue(graph, mappedElement, propertyName);
}
catch (DatabaseException e) {
}