]> gerrit.simantics Code Review - simantics/district.git/blobdiff - org.simantics.district.network.ui/src/org/simantics/district/network/ui/function/Functions.java
Arrow length indicators for flow magnitude
[simantics/district.git] / org.simantics.district.network.ui / src / org / simantics / district / network / ui / function / Functions.java
index 627561a12ca04dba26d84676c22e6eaead598405..60dd3e22131ee17b4ba9890052d5c5d0fca6fe2e 100644 (file)
@@ -483,7 +483,13 @@ public class Functions {
         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);
@@ -497,6 +503,13 @@ public class Functions {
         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);