X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.scl.runtime%2Fscl%2FStringIO.scl;h=a6bf0bffaf68fc347ec100e4117424bdb4fb9b40;hp=1971afc83ad3e259dedc1b3db42f4d7daba9cf3a;hb=0807209928f01e95669af6aeb671110209774bc6;hpb=d2897ed06374eee4d91ba495c71c47eef370c52e diff --git a/bundles/org.simantics.scl.runtime/scl/StringIO.scl b/bundles/org.simantics.scl.runtime/scl/StringIO.scl index 1971afc83..a6bf0bffa 100644 --- a/bundles/org.simantics.scl.runtime/scl/StringIO.scl +++ b/bundles/org.simantics.scl.runtime/scl/StringIO.scl @@ -1,13 +1,25 @@ importJava "org.simantics.scl.runtime.procedure.StringIO" where - "Reads all lines of the file whose name is given as a parameter" + """ + Reads all lines of the file whose name is given as a parameter. + The file contents are expected to be UTF8 encoded. + """ readLines :: String -> [String] "`readLinesWithCharset \"charset\" \"file\"` reads all lines of the file whose name is given as a parameter using the given charset." readLinesWithCharset :: String -> String -> [String] - "Creates a new file with the given file name whose contents are the given lines." + "`readContentsWithCharset \"charset\" \"file\"` reads all lines of the file whose name is given as a parameter using the given charset." + readContentsWithCharset :: String -> String -> 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] -> () - "`appendLine fileName line` appends `line` to the file with name `fileName`" + """ + `appendLine fileName line` appends `line` to the file with name `fileName` + The appended content will be UTF8 encoded. + """ appendLine :: String -> String -> ()