AdapterInterface
extends
ReadInterface
in
Table of Contents
Constants
- VISIBILITY_PRIVATE = 'private'
- VISIBILITY_PUBLIC = 'public'
Methods
- copy() : bool
- Copy a file.
- createDir() : array<string|int, mixed>|false
- Create a directory.
- delete() : bool
- Delete a file.
- deleteDir() : bool
- Delete a directory.
- getMetadata() : array<string|int, mixed>|false
- Get all the meta data of a file or directory.
- getMimetype() : array<string|int, mixed>|false
- Get the mimetype of a file.
- getSize() : array<string|int, mixed>|false
- Get the size of a file.
- getTimestamp() : array<string|int, mixed>|false
- Get the last modified time of a file as a timestamp.
- getVisibility() : array<string|int, mixed>|false
- Get the visibility of a file.
- has() : array<string|int, mixed>|bool|null
- Check whether a file exists.
- listContents() : array<string|int, mixed>
- List contents of a directory.
- read() : array<string|int, mixed>|false
- Read a file.
- readStream() : array<string|int, mixed>|false
- Read a file as a stream.
- rename() : bool
- Rename a file.
- setVisibility() : array<string|int, mixed>|false
- Set the visibility for a file.
- update() : array<string|int, mixed>|false
- Update a file.
- updateStream() : array<string|int, mixed>|false
- Update a file using a stream.
- write() : array<string|int, mixed>|false
- Write a new file.
- writeStream() : array<string|int, mixed>|false
- Write a new file using a stream.
Constants
VISIBILITY_PRIVATE
public
mixed
VISIBILITY_PRIVATE
= 'private'
Tags
VISIBILITY_PUBLIC
public
mixed
VISIBILITY_PUBLIC
= 'public'
Tags
Methods
copy()
Copy a file.
public
copy(string $path, string $newpath) : bool
Parameters
- $path : string
- $newpath : string
Return values
boolcreateDir()
Create a directory.
public
createDir(string $dirname, Config $config) : array<string|int, mixed>|false
Parameters
- $dirname : string
-
directory name
- $config : Config
Return values
array<string|int, mixed>|falsedelete()
Delete a file.
public
delete(string $path) : bool
Parameters
- $path : string
Return values
booldeleteDir()
Delete a directory.
public
deleteDir(string $dirname) : bool
Parameters
- $dirname : string
Return values
boolgetMetadata()
Get all the meta data of a file or directory.
public
getMetadata(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsegetMimetype()
Get the mimetype of a file.
public
getMimetype(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsegetSize()
Get the size of a file.
public
getSize(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsegetTimestamp()
Get the last modified time of a file as a timestamp.
public
getTimestamp(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsegetVisibility()
Get the visibility of a file.
public
getVisibility(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsehas()
Check whether a file exists.
public
has(string $path) : array<string|int, mixed>|bool|null
Parameters
- $path : string
Return values
array<string|int, mixed>|bool|nulllistContents()
List contents of a directory.
public
listContents([string $directory = '' ][, bool $recursive = false ]) : array<string|int, mixed>
Parameters
- $directory : string = ''
- $recursive : bool = false
Return values
array<string|int, mixed>read()
Read a file.
public
read(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falsereadStream()
Read a file as a stream.
public
readStream(string $path) : array<string|int, mixed>|false
Parameters
- $path : string
Return values
array<string|int, mixed>|falserename()
Rename a file.
public
rename(string $path, string $newpath) : bool
Parameters
- $path : string
- $newpath : string
Return values
boolsetVisibility()
Set the visibility for a file.
public
setVisibility(string $path, string $visibility) : array<string|int, mixed>|false
Parameters
- $path : string
- $visibility : string
Return values
array<string|int, mixed>|false —file meta data
update()
Update a file.
public
update(string $path, string $contents, Config $config) : array<string|int, mixed>|false
Parameters
- $path : string
- $contents : string
- $config : Config
-
Config object
Return values
array<string|int, mixed>|false —false on failure file meta data on success
updateStream()
Update a file using a stream.
public
updateStream(string $path, resource $resource, Config $config) : array<string|int, mixed>|false
Parameters
- $path : string
- $resource : resource
- $config : Config
-
Config object
Return values
array<string|int, mixed>|false —false on failure file meta data on success
write()
Write a new file.
public
write(string $path, string $contents, Config $config) : array<string|int, mixed>|false
Parameters
- $path : string
- $contents : string
- $config : Config
-
Config object
Return values
array<string|int, mixed>|false —false on failure file meta data on success
writeStream()
Write a new file using a stream.
public
writeStream(string $path, resource $resource, Config $config) : array<string|int, mixed>|false
Parameters
- $path : string
- $resource : resource
- $config : Config
-
Config object
Return values
array<string|int, mixed>|false —false on failure file meta data on success