return baseMappingModifier(graph, element, DistrictNetworkResource.getInstance(graph).HasMapping, mappingType, context);
}
- public static Map<String, Resource> getVertexMappings(ReadGraph graph, Resource resource) throws DatabaseException {
- Map<String, Resource> second = getNetworkMappingsByType(graph, resource , DistrictNetworkResource.getInstance(graph).Mapping_VertexMapping);
+ public static Map<String, Resource> getVertexMappings(ReadGraph graph, Resource indexRoot) throws DatabaseException {
+ Map<String, Resource> second = getNetworkMappingsByType(graph, indexRoot, DistrictNetworkResource.getInstance(graph).Mapping_VertexMapping);
return second;
}
- public static Map<String, Resource> getEdgeMappings(ReadGraph graph, Resource resource) throws DatabaseException {
- Map<String, Resource> second = getNetworkMappingsByType(graph, resource , DistrictNetworkResource.getInstance(graph).Mapping_EdgeMapping);
+ public static Map<String, Resource> getEdgeMappings(ReadGraph graph, Resource indexRoot) throws DatabaseException {
+ Map<String, Resource> second = getNetworkMappingsByType(graph, indexRoot, DistrictNetworkResource.getInstance(graph).Mapping_EdgeMapping);
return second;
}
public static Map<String, Resource> getCRSs(ReadGraph graph, Resource resource) throws DatabaseException {
- Map<String, Resource> result = getNetworkMappingsByType(graph, resource, DistrictNetworkResource.getInstance(graph).SpatialRefSystem);
+ Map<String, Resource> result = getNetworkMappingsByType(graph, graph.sync(new IndexRoot(resource)), DistrictNetworkResource.getInstance(graph).SpatialRefSystem);
return result;
}
- public static Map<String, Resource> getNetworkMappingsByType(ReadGraph graph, Resource element, Resource mappingType) throws DatabaseException {
- Resource indexRoot = graph.sync(new IndexRoot(element));
+ public static Map<String, Resource> getNetworkMappingsByType(ReadGraph graph, Resource indexRoot, Resource mappingType) throws DatabaseException {
List<Resource> mappings = QueryIndexUtils.searchByType(graph, indexRoot, mappingType);
Map<String, Resource> result = new HashMap<>(mappings.size());
Layer0 L0 = Layer0.getInstance(graph);
@Override
public void run(ReadGraph graph) throws DatabaseException {
-
- vertexMappings = getVertexMappings(graph, configuration);
- edgeMappings = getEdgeMappings(graph, configuration);
+ Resource indexRoot = graph.sync(new IndexRoot(configuration));
+ vertexMappings = getVertexMappings(graph, indexRoot);
+ edgeMappings = getEdgeMappings(graph, indexRoot);
composites = getComposites(graph, configuration);
DistrictNetworkResource DN = DistrictNetworkResource.getInstance(graph);
return listInstanceNames(graph, context, DN.Edge_ThicknessProperty);
}
-
+
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> b")
+ public static Object arrowLengthPropertyEnumerationValues(ReadGraph graph, Resource resource, Variable context) throws DatabaseException {
+ DistrictNetworkResource DN = DistrictNetworkResource.getInstance(graph);
+ return listInstanceNames(graph, context, DN.Edge_ArrowLengthProperty);
+ }
+
@SCLValue(type = "ReadGraph -> Resource -> Variable -> b")
public static Object nodeScalePropertyEnumerationValues(ReadGraph graph, Resource resource, Variable context) throws DatabaseException {
DistrictNetworkResource DN = DistrictNetworkResource.getInstance(graph);
return baseMappingModifier(graph, diagram, DN.Diagram_edgeThicknessProperty, DN.Edge_ThicknessProperty, context);
}
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> b")
+ public static Object arrowLengthPropertyModifier(ReadGraph graph, Resource resource, Variable context) throws DatabaseException {
+ Resource diagram = resolveElement(graph, context);
+ DistrictNetworkResource DN = DistrictNetworkResource.getInstance(graph);
+ return baseMappingModifier(graph, diagram, DN.Diagram_arrowLengthProperty, DN.Edge_ArrowLengthProperty, context);
+ }
+
@SCLValue(type = "ReadGraph -> Resource -> Variable -> b")
public static Object nodeScalePropertyModifier(ReadGraph graph, Resource resource, Variable context) throws DatabaseException {
Resource diagram = resolveElement(graph, context);