FileWriter

Extends \OutputStreamWriter

Convenience class for performing file write operations.

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

Methods

Construct a new OutputStreamWriter.

__construct(\OutputStream $outStream) 
inherited

Arguments

$outStream

\OutputStream

OutputStream to write to

Close the stream.

close() 
inherited abstract
throws
  • if there is an error closing stream.

Writes data to output stream.

write(string $buf, int $off = null, int $len = null) 
inherited abstract

Arguments

$buf

string

$off

int

$len

int

Flush the stream, if supported by the stream.

flush() 
inherited

Returns a string representation of resource filename, url, etc. that is being written to.

getResource() : string
inherited abstract

Response

string

Properties

outStream

outStream : \OutputStream
inherited
var

Type(s)

\OutputStream