Home Cooker Classes Others Rice CookerGX
Classes  >  reader  >  reader(string,bool)
reader class : reader(string,bool) fitter

Description

Initializes a new instance of reader type for the specified file name, with the specified byte order mark detection option.

Syntax

new reader(string fullPath, bool detectBOM)

Arguments

ClassNameDescription
stringfullPathThe complete file path.
booldetectBOMA value that indicates whether detect the BOM.

Return value

ClassDescription
readerA reader type instance that was initialized by specified value.

Sample code

reader readerInstance = new reader("c:\Users\....\target.txt", true);

Notes

It's a wrapper of the System.IO.StreamReader.StreamReader(String,Encoding).

The Encoding is UTF-8.

You can specify detection of the Unicode byte order mark(BOM) with second argument.

If true, detects a Unicode byte order mark(BOM). Otherwise, does nothing.

Links for reference

Copyright © Rice All rights reserved.