Please note that the contents
of this offline web site may be out of date. To access the most
recent documentation visit the
online version
.
Note that links that point to online resources are
green
in color and will open in a new
window.
We would love it if you could give us feedback about this material
by filling
this form
(You have to be online to fill it)
third_party/vfsstream/vendor/mikey179/vfsStream/src/main/php/org/bovigo/vfs/vfsStreamWrapper.php
This file is part of vfsStream.
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
-
Package
-
org\bovigo\vfs
\org\bovigo\vfs\vfsStreamWrapper
Package:
Default
Stream wrapper to mock file system requests.
-
Children
-
\org\bovigo\vfs\vfsStreamWrapperRecordingProxy
-
\org\bovigo\vfs\TestvfsStreamWrapper
Constants
Methods
register
()
: void
static
method to register the stream wrapper
Please be aware that a call to this method will reset the root element
to null.
If the stream is already registered the method returns silently. If there
is already another stream wrapper registered for the scheme used by
vfsStream a vfsStreamException will be thrown.
Throws
rename
(string $path_from, string $path_to)
: bool
rename from one path to another
Parameters
Name
|
Type
|
Description
|
$path_from
|
string
|
|
$path_to
|
string
|
|
Returns
Details
-
Author
-
Benoit Aubuchon
setQuota
(\org\bovigo\vfs\Quota $quota)
: void
static
sets quota for disk space
Parameters
Name
|
Type
|
Description
|
$quota
|
\org\bovigo\vfs\Quota
|
|
Details
-
Since
-
1.1.0
stream_cast
(int $cast_as)
: bool
retrieve the underlaying resource
Please note that this method always returns false as there is no
underlaying resource to return.
Parameters
Name
|
Type
|
Description
|
$cast_as
|
int
|
|
Returns
Details
-
See
-
\org\bovigo\vfs\https://github.com/mikey179/vfsStream/issues/3
-
Since
-
0.9.0
stream_lock
(int $operation)
: bool
set lock status for stream
Parameters
Name
|
Type
|
Description
|
$operation
|
int
|
|
Returns
Details
-
See
-
\org\bovigo\vfs\https://github.com/mikey179/vfsStream/issues/6
-
See
-
\org\bovigo\vfs\https://github.com/mikey179/vfsStream/issues/31
-
See
-
\org\bovigo\vfs\https://github.com/mikey179/vfsStream/issues/40
-
Since
-
0.10.0
stream_metadata
(string $path, int $option, mixed $var)
: bool
sets metadata like owner, user or permissions
Parameters
Name
|
Type
|
Description
|
$path
|
string
|
|
$option
|
int
|
|
$var
|
mixed
|
|
Returns
Details
-
Since
-
1.1.0
stream_open
(string $path, string $mode, string $options, string $opened_path)
: bool
Parameters
Name
|
Type
|
Description
|
$path
|
string
|
the path to open
|
$mode
|
string
|
mode for opening
|
$options
|
string
|
options for opening
|
$opened_path
|
string
|
full path that was actually opened
|
Returns
stream_read
(int $count)
: string
read the stream up to $count bytes
Parameters
Name
|
Type
|
Description
|
$count
|
int
|
amount of bytes to read
|
Returns
stream_seek
(int $offset, int $whence)
: bool
seeks to the given offset
Parameters
Name
|
Type
|
Description
|
$offset
|
int
|
|
$whence
|
int
|
|
Returns
stream_set_option
(int $option, int $arg1, int $arg2)
: bool
sets options on the stream
Parameters
Name
|
Type
|
Description
|
$option
|
int
|
key of option to set
|
$arg1
|
int
|
|
$arg2
|
int
|
|
Returns
Details
-
See
-
\org\bovigo\vfs\https://github.com/mikey179/vfsStream/issues/15
-
See
-
\org\bovigo\vfs\http://www.php.net/manual/streamwrapper.stream-set-option.php
-
Since
-
0.10.0
stream_truncate
(int $size)
: bool
truncates a file to a given length
Parameters
Name
|
Type
|
Description
|
$size
|
int
|
length to truncate file to
|
Returns
Details
-
Since
-
1.1.0
stream_write
(string $data)
: int
writes data into the stream
Parameters
Name
|
Type
|
Description
|
$data
|
string
|
|
Returns
Type
|
Description
|
int
|
amount of bytes written
|
unlink
(string $path)
: bool
remove the data under the given path
Parameters
Name
|
Type
|
Description
|
$path
|
string
|
|
Returns
url_stat
(string $path, int $flags)
: array
Parameters
Name
|
Type
|
Description
|
$path
|
string
|
path of url to return status for
|
$flags
|
int
|
flags set by the stream API
|
Returns