reader class : reader(string,string,bool) fitter
Description
Initializes and returns a new instance of reader class with file name, character encoding, and reading mode setting option.
Syntax
new reader(string fullPath, string encodingName, bool readOnly)
Arguments
Class | Name | Description |
string | fullPath | The complete file path. |
string | encodingName | Encoding name. |
bool | readOnly | A value that indicates reading mode. |
Return value
Class | Description |
reader | An instance that was initialized by specified value. |
Sample code
1: | reader r = new reader("c:\somewhere...\sample.txt", "shift_jis", true); |
Notes
It's a wrapper of the System.IO.StreamReader.StreamReader(String,Encoding,Boolean) constructor. changed in ver 1.0.0.2
You can specify the encoding with second argument. The encoding will be specified by encoding name.
You can specify detection of the Unicode byte order mark(BOM) with third argument. changed in ver 1.0.0.2
If true, detects a Unicode byte order mark(BOM). Otherwise, does nothing. changed in ver 1.0.0.2
You can specify the reading mode with third argument.
If true, open the file in Read Only mode. In this case, no exception occurs even if the file is opened by another process.
If false, an exception will occur if the file is open in another process.
The meaning of the third argument has been changed in Rtype.Reader.dll Ver 1.0.0.2.