streamWrapper::url_stat
Retrieve information about a file
Description
public array streamWrapper::url_stat
( string $path
, int $flags
)
- chmod (only when safe_mode is enabled)
- copy
- fileperms
- fileinode
- filesize
- fileowner
- filegroup
- fileatime
- filemtime
- filectime
- filetype
- is_writable
- is_readable
- is_executable
- is_file
- is_dir
- is_link
- file_exists
- lstat
- stat
- SplFileInfo::getPerms
- SplFileInfo::getInode
- SplFileInfo::getSize
- SplFileInfo::getOwner
- SplFileInfo::getGroup
- SplFileInfo::getATime
- SplFileInfo::getMTime
- SplFileInfo::getCTime
- SplFileInfo::getType
- SplFileInfo::isWritable
- SplFileInfo::isReadable
- SplFileInfo::isExecutable
- SplFileInfo::isFile
- SplFileInfo::isDir
- SplFileInfo::isLink
- RecursiveDirectoryIterator::hasChildren
Parameters
-
path
-
The file path or URL to stat. Note that in the case of a URL, it must be a :// delimited
URL. Other URL forms are not supported.
-
flags
-
Holds additional flags set by the streams API. It can hold one or more
of the following values OR'd together.
Return Values
Should return as many elements as stat does.
Unknown or unavailable values should be set to a rational value
(usually 0
).
Errors/Exceptions
Emits
E_WARNING
if call to this method fails
(i.e. not implemented).
Notes
Note:
The
streamWrapper::$context
property is updated if a valid context is passed to the caller function.
See Also
- stat
- streamwrapper::stream_stat