Specifies an encoding to use when reading a file in a relevance expression.
encoding could be any name that the International Components for Unicode (ICU) can recognize, such as "ISO-8859-1", "Shift_JIS", and "UTF-8". Once created, the
file objects can be used as regular
file objects and you can apply any operation applicable to text files. If no encoding is specified, the files are read in the local encoding.
These are some examples:
- Q: (content of file "c:\aaa\bbb.txt" of encoding "Shift_JIS") contains "うみ"
returns if the word "うみ" is found in the file "c:\aaa\bbb.txt" that is written in Shift_JIS.
- Q: line 3 of file "eee.txt" of folder "/ccc/ddd" of encoding "Windows-1252"
returns the third line of the file "/ccc/ddd/eee.log" in Windows-1252.
- Q: key "やま" of section "其之弐" of file "f:\ggg\hhh.ini" of encoding "UTF-8"
returns Returns the value of the "やま" key in the "其之弐" section of the file "f:\ggg\hhh.ini" that is written in UTF-8.
|184.108.40.206||AIX, Debian, Mac, Red Hat, SUSE, Solaris, Ubuntu, Windows|