summaryrefslogtreecommitdiffstats
path: root/apps/dav/lib/Avatars/RootCollection.php
blob: 8cad3d3721ab43582ececb20b48c4e928686815d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?php

namespace OCA\DAV\Avatars;

use Sabre\DAVACL\AbstractPrincipalCollection;
use Sabre\DAVACL\IPrincipal;

class RootCollection extends AbstractPrincipalCollection {

	/**
	 * This method returns a node for a principal.
	 *
	 * The passed array contains principal information, and is guaranteed to
	 * at least contain a uri item. Other properties may or may not be
	 * supplied by the authentication backend.
	 *
	 * @param array $principalInfo
	 * @return IPrincipal
	 */
	function getChildForPrincipal(array $principalInfo) {
		return new AvatarHome($principalInfo);
	}

	function getName() {
		return 'avatars';
	}

}