Convenience class for reading files.
Unlike the Java counterpart, this class does not (yet) handle character set transformations. This will be an important function of this class with move to supporting PHP6.
| package | phing.system.io |
|---|---|
| author | Hans Lellelid |
| author | Yannick Lecaillez |
| version | $Id$ |
__construct(mixed $file)
mixedPhingFile or string pathname.
close()
| inherited_from | \InputStreamReader::close() |
|---|
\IOException |
if there is an error closing stream |
|---|
eof() : boolean
| inherited_from | \InputStreamReader::eof() |
|---|
booleangetResource() : string
that is being read from. This is critical for, e.g., ExpatParser's ability to know the filename that is throwing an ExpatParserException, etc.
| inherited_from | \InputStreamReader::getResource() |
|---|
stringmark()
A subsequent call to reset() will move stream position back to last marker (if supported).
| inherited_from | \InputStreamReader::mark() |
|---|
\IOException |
- if the underlying stream doesn't support this method. |
|---|
markSupported() : boolean
| inherited_from | \InputStreamReader::markSupported() |
|---|
booleanread(int $len) : string
If length is specified, then only that number of chars is read, otherwise stream is read until EOF.
| inherited_from | \InputStreamReader::read() |
|---|
intNum chars to read.
stringchars read or -1 if eof.readInto($rBuffer) : TRUE
| author | Charlie Killian, charlie@tizac.com |
|---|---|
| inherited_from | \InputStreamReader::readInto() |
TRUEon success. Err object on failure.ready() : boolean
| inherited_from | \Reader::ready() |
|---|---|
| inherited_from | \InputStreamReader::ready() |
booleanreset()
| inherited_from | \InputStreamReader::reset() |
|---|
\IOException |
- if the underlying stream doesn't support this method. |
|---|
skip(int $n)
| inherited_from | \InputStreamReader::skip() |
|---|
int