PHP Class pchStringStream, php-commit-hooks

Show file Open project: kore/php-commit-hooks

Protected Properties

Property Type Description
$length integer Cached length of the string
$position integer Current position inside the string
$string string String, wrapped by the stream

Public Methods

Method Description
stream_eof ( ) : boolean Has the stream reached its end?
stream_open ( string $path, string $mode, mixed $options, mixed &$opened_path ) : boolean Open stream
stream_read ( integer $count ) : string Read from stream
stream_seek ( integer $offset, integer $whence ) : boolean Seek to a defined position in the string
stream_stat ( ) : void Returns information about the stream
stream_tell ( ) : integer Tell current stream position
stream_write ( string $data ) : integer Write to stream

Method Details

stream_eof() public method

Has the stream reached its end?
public stream_eof ( ) : boolean
return boolean

stream_open() public method

Open stream
public stream_open ( string $path, string $mode, mixed $options, mixed &$opened_path ) : boolean
$path string
$mode string
$options mixed
$opened_path mixed
return boolean

stream_read() public method

Read from stream
public stream_read ( integer $count ) : string
$count integer
return string

stream_seek() public method

Seek to a defined position in the string
public stream_seek ( integer $offset, integer $whence ) : boolean
$offset integer
$whence integer
return boolean

stream_stat() public method

Returns information about the stream
public stream_stat ( ) : void
return void

stream_tell() public method

Tell current stream position
public stream_tell ( ) : integer
return integer

stream_write() public method

Write to stream
public stream_write ( string $data ) : integer
$data string
return integer

Property Details

$length protected property

Cached length of the string
protected int $length
return integer

$position protected property

Current position inside the string
protected int $position
return integer

$string protected property

String, wrapped by the stream
protected string $string
return string