Elgg  Version 4.3
ElggFilestore.php
Go to the documentation of this file.
1 <?php
5 abstract class ElggFilestore {
14  abstract public function open(\ElggFile $file, $mode);
15 
24  abstract public function write($f, $data);
25 
35  abstract public function read($f, $length, $offset = 0);
36 
45  abstract public function seek($f, $position);
46 
54  abstract public function eof($f);
55 
63  abstract public function tell($f);
64 
72  abstract public function close($f);
73 
81  abstract public function delete(\ElggFile $file, $follow_symlinks = true);
82 
90  abstract public function getFileSize(\ElggFile $file);
91 
99  abstract public function getFilenameOnFilestore(\ElggFile $file);
100 
107  abstract public function getParameters();
108 
116  abstract public function setParameters(array $parameters);
117 
125  abstract public function grabFile(\ElggFile $file);
126 
134  abstract public function exists(\ElggFile $file);
135 }
write($f, $data)
Write data to a given file handle.
exists(\ElggFile $file)
Return whether a file physically exists or not.
$mode
Configure site maintenance mode.
if(!$item instanceof ElggEntity) $length
Definition: excerpt.php:16
setParameters(array $parameters)
Set the parameters from the associative array produced by $this->getParameters(). ...
getFileSize(\ElggFile $file)
Return the size in bytes for a given file.
if(elgg_trigger_plugin_hook('usersettings:save', 'user', $hooks_params, true)) foreach($request->validation() ->all() as $item) $data
Definition: save.php:53
if(!$count) $offset
Definition: pagination.php:26
seek($f, $position)
Seek a given position within a file handle.
$position
Definition: move.php:7
read($f, $length, $offset=0)
Read data from a filestore.
getParameters()
Get the filestore&#39;s creation parameters as an associative array.
grabFile(\ElggFile $file)
Get the contents of the whole file.
tell($f)
Return the current position in an open file.
open(\ElggFile $file, $mode)
Attempt to open the file $file for storage or writing.
eof($f)
Return a whether the end of a file has been reached.
This class defines the interface for all elgg data repositories.
getFilenameOnFilestore(\ElggFile $file)
Return the filename of a given file as stored on the filestore.
close($f)
Close a given file handle.