]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.layer0/graph/Layer0Values.pgraph
Merge "Defined L0.ValueType to make L0.Value(s) searchable from index"
[simantics/platform.git] / bundles / org.simantics.layer0 / graph / Layer0Values.pgraph
index 18fd6d25c955eb8d9899d0a8dce42eadabd9fea6..14aa774e8e6111642b569c2dd261121a7b686d8b 100644 (file)
@@ -1,6 +1,8 @@
 L0 = <http://www.simantics.org/Layer0-1.1>
 
-L0.Value <T L0.Entity
+L0.Value <T L0.Entity : L0.ValueType
+
+L0.ValueType <T L0.Type
     
 L0.ExternalValue <T L0.Value
 
@@ -16,7 +18,7 @@ L0.RequiresValueType <R L0.HasProperty : L0.FunctionalRelation
     <-- L0.Relation
     --> L0.String
 
-L0.HasDefaultLiteralType <R L0.DependsOn : L0.FunctionalRelation    
+L0.HasDefaultLiteralType <R L0.DependsOn : L0.FunctionalRelation
     <-- L0.Relation
     --> L0.Type
     
@@ -24,11 +26,14 @@ L0.HasSubliteralPredicate <R L0.DependsOn
 
 L0.RVIContext <T L0.Entity
 
-L0.SCLValue <T L0.Value
+L0.SCLValue <T L0.Value : L0.SCLValueType
     @L0.tag L0.Abstract
     >-- L0.SCLValue.expression --> L0.String <R L0.HasProperty : L0.TotalFunction
     >-- L0.SCLValue.environment --> L0.SCLValue.Environment <R L0.IsRelatedTo : L0.TotalFunction
-    @L0.assert L0.ConvertsToValueWith L0.Functions.computeExpression
+    @L0.assert L0.ConvertsToValueWith L0.Functions.sclValue
+
+L0.SCLValueType <T L0.ValueType
+    >-- L0.SCLValueType.validator ==> "Variable -> <ReadGraph> String" <R L0.HasProperty
 
 L0.scl : L0.Template
     @template %subject %property %expression %valueType
@@ -37,6 +42,15 @@ L0.scl : L0.Template
               L0.SCLValue.expression %expression
               L0.HasValueType %valueType
 
+L0.sclAssertion : L0.Template
+    @template %type %property %expression %valueType
+        %type
+            L0.Asserts _ : L0.Assertion
+              L0.HasPredicate %property
+              L0.HasObject _ : L0.SCLValue
+                L0.SCLValue.expression %expression
+                L0.HasValueType %valueType
+
 L0.SCLValue.Environment <T L0.Entity
     >-- L0.SCLValue.Environment.moduleName --> L0.String <R L0.HasProperty : L0.TotalFunction
     >-- L0.SCLValue.Environment.namespace --> L0.String <R L0.HasProperty : L0.TotalFunction
@@ -47,5 +61,3 @@ L0.Property <T L0.Value
     @L0.tag L0.Abstract
     @L0.tag L0.Deprecated
     @L0.assert L0.ConvertsToValueWith L0.Functions.composedPropertyValue
-    
-    
\ No newline at end of file