StreamWrapper
in package
FinalYes
Converts Guzzle streams into PHP stream resources.
Tags
Table of Contents
Properties
- $context : resource
Methods
- createStreamContext() : resource
- Creates a stream context that can be used to open a stream as a php stream resource.
- getResource() : resource
- Returns a resource representing the stream.
- register() : void
- Registers the stream wrapper if needed
- stream_cast() : resource|false
- stream_eof() : bool
- stream_open() : bool
- stream_read() : string
- stream_seek() : bool
- stream_stat() : array{dev: int, ino: int, mode: int, nlink: int, uid: int, gid: int, rdev: int, size: int, atime: int, mtime: int, ctime: int, blksize: int, blocks: int}|false
- stream_tell() : int
- stream_write() : int
- url_stat() : array{dev: int, ino: int, mode: int, nlink: int, uid: int, gid: int, rdev: int, size: int, atime: int, mtime: int, ctime: int, blksize: int, blocks: int}
Properties
$context
public
resource
$context
Methods
createStreamContext()
Creates a stream context that can be used to open a stream as a php stream resource.
public
static createStreamContext(StreamInterface $stream) : resource
Parameters
- $stream : StreamInterface
Return values
resourcegetResource()
Returns a resource representing the stream.
public
static getResource(StreamInterface $stream) : resource
Parameters
- $stream : StreamInterface
-
The stream to get a resource for
Tags
Return values
resourceregister()
Registers the stream wrapper if needed
public
static register() : void
stream_cast()
public
stream_cast(int $cast_as) : resource|false
Parameters
- $cast_as : int
Return values
resource|falsestream_eof()
public
stream_eof() : bool
Return values
boolstream_open()
public
stream_open(string $path, string $mode, int $options[, string|null &$opened_path = null ]) : bool
Parameters
- $path : string
- $mode : string
- $options : int
- $opened_path : string|null = null
Return values
boolstream_read()
public
stream_read(int $count) : string
Parameters
- $count : int
Return values
stringstream_seek()
public
stream_seek(int $offset, int $whence) : bool
Parameters
- $offset : int
- $whence : int
Return values
boolstream_stat()
public
stream_stat() : array{dev: int, ino: int, mode: int, nlink: int, uid: int, gid: int, rdev: int, size: int, atime: int, mtime: int, ctime: int, blksize: int, blocks: int}|false
Return values
array{dev: int, ino: int, mode: int, nlink: int, uid: int, gid: int, rdev: int, size: int, atime: int, mtime: int, ctime: int, blksize: int, blocks: int}|falsestream_tell()
public
stream_tell() : int
Return values
intstream_write()
public
stream_write(string $data) : int
Parameters
- $data : string
Return values
inturl_stat()
public
url_stat(string $path, int $flags) : array{dev: int, ino: int, mode: int, nlink: int, uid: int, gid: int, rdev: int, size: int, atime: int, mtime: int, ctime: int, blksize: int, blocks: int}
Parameters
- $path : string
- $flags : int