# Writer

Abstract class for writing character streams.

package | phing.system.io

### Methods

## Close the stream.

    close()

abstract

throws

- if there is an error closing stream.

## Flush the stream, if supported by the stream.

    flush()

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

    getResource() : string

abstract

### Response

`string`

## Writes data to output stream.

    write(string $buf, integer $off = null, integer $len = null)

abstract

### Arguments

#### $buf

`string`

#### $off

`integer`

#### $len

`integer`