Documentation

This commit is contained in:
Robin Appelman 2017-02-01 14:56:25 +01:00
commit 3f23e989f0
8 changed files with 152 additions and 21 deletions

View file

@ -29,7 +29,17 @@ class Order implements XmlDeserializable {
const ASC = 'ascending';
const DESC = 'descending';
public $properties;
/**
* @var string
*
* The property that should be sorted on.
*/
public $property;
/**
* @var string 'ascending' or 'descending'
*
* The sort direction
*/
public $order;
static function xmlDeserialize(Reader $reader) {
@ -38,7 +48,7 @@ class Order implements XmlDeserializable {
$childs = \Sabre\Xml\Deserializer\keyValue($reader);
$order->order = isset($childs['{DAV:}descending']) ? self::DESC : self::ASC;
$order->properties = $childs['{DAV:}prop'];
$order->property = $childs['{DAV:}prop'][0];
return $order;
}