]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.scl.data/examples/XMLTransformationTest.scl
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.scl.data / examples / XMLTransformationTest.scl
index af2a5098dfcbf933cb0f6802642f3d0da0f935bb..90340a7387a83854fb80071205242407d697b388 100644 (file)
@@ -1,26 +1,26 @@
-import "Data/XML"\r
-\r
-mapping relation MapNote Element Element\r
-\r
-rule SectionsRule where\r
-    @when\r
-    MapNote ?noteA ?noteB\r
-    ?sectionName <- ["from", "to", "heading", "body"]\r
-    \r
-    @from\r
-    Attribute ?noteA ?sectionName ?text\r
-    \r
-    @to\r
-    Element ?noteB ?sectionName ?el\r
-    TextContent ?el ?text\r
-    \r
-main () = do\r
-    doc = parseString """<note to="Tove" from="Jani" heading="Reminder" body="Don't forget me this weekend!"/>"""\r
-\r
-    doc2 = parseString "<note/>"\r
-\r
-    transformation OneShotForward where\r
-        MapNote (rootElementOf doc) (rootElementOf doc2)\r
-    \r
-    print $ outputString doc2\r
+import "Data/XML"
+
+mapping relation MapNote Element Element
+
+rule SectionsRule where
+    @when
+    MapNote ?noteA ?noteB
+    ?sectionName <- ["from", "to", "heading", "body"]
+    
+    @from
+    Attribute ?noteA ?sectionName ?text
+    
+    @to
+    Element ?noteB ?sectionName ?el
+    TextContent ?el ?text
+    
+main () = do
+    doc = parseString """<note to="Tove" from="Jani" heading="Reminder" body="Don't forget me this weekend!"/>"""
+
+    doc2 = parseString "<note/>"
+
+    transformation OneShotForward where
+        MapNote (rootElementOf doc) (rootElementOf doc2)
+    
+    print $ outputString doc2
     
\ No newline at end of file