-\r
-importJava "org.simantics.scl.runtime.procedure.StringIO" where\r
- "Reads all lines of the file whose name is given as a parameter"\r
- readLines :: String -> <Proc> [String]\r
- \r
- "`readLinesWithCharset \"charset\" \"file\"` reads all lines of the file whose name is given as a parameter using the given charset."\r
- readLinesWithCharset :: String -> String -> <Proc> [String]\r
- \r
- "Creates a new file with the given file name whose contents are the given lines."\r
- writeLines :: String -> [String] -> <Proc> ()\r
- \r
- "`appendLine fileName line` appends `line` to the file with name `fileName`"\r
- appendLine :: String -> String -> <Proc> ()\r
+
+importJava "org.simantics.scl.runtime.procedure.StringIO" where
+ """
+ Reads all lines of the file whose name is given as a parameter.
+ The file contents are expected to be UTF8 encoded.
+ """
+ readLines :: String -> <Proc> [String]
+
+ "`readLinesWithCharset \"charset\" \"file\"` reads all lines of the file whose name is given as a parameter using the given charset."
+ readLinesWithCharset :: String -> String -> <Proc> [String]
+
+ "`readContentsWithCharset \"charset\" \"file\"` reads all lines of the file whose name is given as a parameter using the given charset."
+ readContentsWithCharset :: String -> String -> <Proc> String
+
+ """
+ Creates a new file with the given file name whose contents are the given lines.
+ The written file will be UTF8 encoded.
+ """
+ writeLines :: String -> [String] -> <Proc> ()
+
+ """
+ `appendLine fileName line` appends `line` to the file with name `fileName`
+ The appended content will be UTF8 encoded.
+ """
+ appendLine :: String -> String -> <Proc> ()