ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
Sabre\DAV\TreeFileTester Class Reference
+ Inheritance diagram for Sabre\DAV\TreeFileTester:
+ Collaboration diagram for Sabre\DAV\TreeFileTester:

Public Member Functions

 __construct ($name, $data=null)
 
 getName ()
 Returns the name of the node. More...
 
 get ()
 Returns the data. More...
 
 getProperties ($properties)
 Returns a list of properties for this nodes. More...
 
 propPatch (PropPatch $propPatch)
 Updates properties on this node. More...
 
- Public Member Functions inherited from Sabre\DAV\File
 put ($data)
 Replaces the contents of the file. More...
 
 get ()
 Returns the data. More...
 
 getSize ()
 Returns the size of the file, in bytes. More...
 
 getETag ()
 Returns the ETag for a file. More...
 
 getContentType ()
 Returns the mime-type for a file. More...
 
- Public Member Functions inherited from Sabre\DAV\Node
 getLastModified ()
 Returns the last modification time as a unix timestamp. More...
 
 delete ()
 Deletes the current node. More...
 
 setName ($name)
 Renames the node. More...
 
 delete ()
 Deleted the current node. More...
 
 getName ()
 Returns the name of the node. More...
 
 setName ($name)
 Renames the node. More...
 
 getLastModified ()
 Returns the last modification time, as a unix timestamp. More...
 
 put ($data)
 Replaces the contents of the file. More...
 
 get ()
 Returns the data. More...
 
 getContentType ()
 Returns the mime-type for a file. More...
 
 getETag ()
 Returns the ETag for a file. More...
 
 getSize ()
 Returns the size of the node, in bytes. More...
 
 propPatch (PropPatch $propPatch)
 Updates properties on this node. More...
 
 getProperties ($properties)
 Returns a list of properties for this nodes. More...
 

Data Fields

 $name
 
 $data
 
 $properties
 

Detailed Description

Definition at line 162 of file TreeTest.php.

Constructor & Destructor Documentation

◆ __construct()

Sabre\DAV\TreeFileTester::__construct (   $name,
  $data = null 
)

Definition at line 168 of file TreeTest.php.

168 {
169
170 $this->name = $name;
171 if (is_null($data)) $data = 'bla';
172 $this->data = $data;
173
174 }
$this data['403_header']

References Sabre\DAV\TreeFileTester\$data, Sabre\DAV\TreeFileTester\$name, and data.

Member Function Documentation

◆ get()

Sabre\DAV\TreeFileTester::get ( )

Returns the data.

This method may either return a string or a readable stream resource

Returns
mixed

Reimplemented from Sabre\DAV\File.

Definition at line 182 of file TreeTest.php.

182 {
183
184 return $this->data;
185
186 }

References Sabre\DAV\TreeFileTester\$data.

◆ getName()

Sabre\DAV\TreeFileTester::getName ( )

Returns the name of the node.

This is used to generate the url.

Returns
string

Implements Sabre\DAV\INode.

Definition at line 176 of file TreeTest.php.

176 {
177
178 return $this->name;
179
180 }

References Sabre\DAV\TreeFileTester\$name.

◆ getProperties()

Sabre\DAV\TreeFileTester::getProperties (   $properties)

Returns a list of properties for this nodes.

The properties list is a list of propertynames the client requested, encoded in clark-notation {xmlnamespace}tagname

If the array is empty, it means 'all properties' were requested.

Note that it's fine to liberally give properties back, instead of conforming to the list of requested properties. The Server class will filter out the extra.

Parameters
array$properties
Returns
array

Implements Sabre\DAV\IProperties.

Definition at line 188 of file TreeTest.php.

188 {
189
190 return $this->properties;
191
192 }

References Sabre\DAV\TreeFileTester\$properties.

◆ propPatch()

Sabre\DAV\TreeFileTester::propPatch ( PropPatch  $propPatch)

Updates properties on this node.

This method received a PropPatch object, which contains all the information about the update.

To update specific properties, call the 'handle' method on this object. Read the PropPatch documentation for more information.

Parameters
PropPatch$propPatch
Returns
void

Implements Sabre\DAV\IProperties.

Definition at line 206 of file TreeTest.php.

206 {
207
208 $this->properties = $propPatch->getMutations();
209 $propPatch->setRemainingResultCode(200);
210
211 }

References Sabre\DAV\PropPatch\getMutations(), and Sabre\DAV\PropPatch\setRemainingResultCode().

+ Here is the call graph for this function:

Field Documentation

◆ $data

Sabre\DAV\TreeFileTester::$data

◆ $name

Sabre\DAV\TreeFileTester::$name

◆ $properties

Sabre\DAV\TreeFileTester::$properties

Definition at line 166 of file TreeTest.php.

Referenced by Sabre\DAV\TreeFileTester\getProperties().


The documentation for this class was generated from the following file: