Flow PHP

SourceStreamWrapper implements StreamWrapper

FinalYes

Serves a SourceStream, read-only and forward-only, to a native reader that opens nothing but a URI, like XMLReader::open().

Interfaces

StreamWrapper

Constants

PROTOCOL  : mixed = 'flow-source'

Properties

$context  : null|resource

Methods

register()  : void
stream_close()  : void
stream_eof()  : bool
stream_flush()  : bool
stream_lock()  : bool
stream_open()  : bool
stream_read()  : string|false
stream_seek()  : bool
stream_stat()  : array<string|int, mixed>|false
stream_tell()  : int
stream_write()  : int
uri()  : string
The URI opens $source once. The source stays the caller's to close.
url_stat()  : array<string|int, mixed>|false
A URI not opened yet exists; libxml stats it before it opens it.

Constants

Properties

Methods

stream_lock()

public stream_lock(int $operation) : bool
Parameters
$operation : int
Return values
bool

stream_open()

public stream_open(string $path, string $mode, int $options, string|null &$opened_path) : bool
Parameters
$path : string
$mode : string
$options : int
$opened_path : string|null
Return values
bool

stream_read()

public stream_read(int $count) : string|false
Parameters
$count : int
Return values
string|false

stream_seek()

public stream_seek(int $offset[, int $whence = SEEK_SET ]) : bool
Parameters
$offset : int
$whence : int = SEEK_SET
Return values
bool

stream_stat()

public stream_stat() : array<string|int, mixed>|false
Return values
array<string|int, mixed>|false

stream_write()

public stream_write(string $data) : int
Parameters
$data : string
Return values
int

uri()

The URI opens $source once. The source stays the caller's to close.

public static uri(SourceStream $source[, int<1, max> $length = 8192 ]) : string
Parameters
$source : SourceStream
$length : int<1, max> = 8192

bytes requested from $source per read

Return values
string

url_stat()

A URI not opened yet exists; libxml stats it before it opens it.

public url_stat(string $path, int $flags) : array<string|int, mixed>|false
Parameters
$path : string
$flags : int
Return values
array<string|int, mixed>|false
On this page

Search results