An object to handle reading text files line by line in a cross platform manner. Using this class instead of the standard angle brackets approach has the following benefits:
| NaturalDocs:: | An object to handle reading text files line by line in a cross platform manner. |
| Constants | |
| Members | |
| Functions | |
| New | Creates and returns a new object. |
| Chomp | Removes any line breaks from the end of a value. |
| StripBOM | Removes the Unicode BOM from the line if present. |
| Get | Returns the next line of text from the file, or undef if there are no more. |
| GetAll | Returns an array of all the lines from the file. |
sub StripBOM #( lineRef )
Removes the Unicode BOM from the line if present. Information on it is available at http://www.unicode.org/faq/utf_bom.html#BOM
| lineRef | A reference to the line to strip. |
Creates and returns a new object.
sub New #( filehandle )
Removes any line breaks from the end of a value.
sub Chomp #( lineRef )
Removes the Unicode BOM from the line if present.
sub StripBOM #( lineRef )
Returns the next line of text from the file, or undef if there are no more.
sub Get
Returns an array of all the lines from the file.
sub GetAll