ILIAS  release_8 Revision v8.24
ilDAVClientNode Class Reference
+ Inheritance diagram for ilDAVClientNode:
+ Collaboration diagram for ilDAVClientNode:

Public Member Functions

 __construct (string $client_name, ilWebDAVObjFactory $dav_factory, ilWebDAVRepositoryHelper $repository_helper)
 
 getName ()
 
 getChild ($name)
 
 getChildren ()
 
 childExists ($name)
 
 getLastModified ()
 

Protected Member Functions

 getRefIdFromName (string $name)
 

Protected Attributes

ilWebDAVObjFactory $dav_factory
 
ilWebDAVRepositoryHelper $repository_helper
 
string $client_name
 
string $name_of_repository_root
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilDAVClientNode::__construct ( string  $client_name,
ilWebDAVObjFactory  $dav_factory,
ilWebDAVRepositoryHelper  $repository_helper 
)

Definition at line 39 of file class.ilDAVClientNode.php.

43 {
44 $this->dav_factory = $dav_factory;
45 $this->repository_helper = $repository_helper;
46 $this->client_name = $client_name;
47 $this->name_of_repository_root = 'ILIAS';
48 }
ilWebDAVRepositoryHelper $repository_helper
ilWebDAVObjFactory $dav_factory

References $client_name, $dav_factory, and $repository_helper.

Member Function Documentation

◆ childExists()

ilDAVClientNode::childExists (   $name)

Definition at line 75 of file class.ilDAVClientNode.php.

75 : bool
76 {
77 try {
79 return $this->repository_helper->objectWithRefIdExists($ref_id) && $this->repository_helper->checkAccess('read', $ref_id);
80 } catch (BadRequest $e) {
81 }
82
83 return $this->checkIfChildExistsByParentRefId($this->repository_helper, $this->dav_factory, ROOT_FOLDER_ID, $name);
84 }
getRefIdFromName(string $name)
const ROOT_FOLDER_ID
Definition: constants.php:32
$ref_id
Definition: ltiauth.php:67
if($format !==null) $name
Definition: metadata.php:247

References Vendor\Package\$e, $name, $ref_id, getRefIdFromName(), and ROOT_FOLDER_ID.

+ Here is the call graph for this function:

◆ getChild()

ilDAVClientNode::getChild (   $name)

Definition at line 55 of file class.ilDAVClientNode.php.

55 : INode
56 {
57 try {
59
60 return $this->dav_factory->retrieveDAVObjectByRefID($ref_id);
61 } catch (NotFound $e) {
62 }
63
64 return $this->getChildByParentRefId($this->repository_helper, $this->dav_factory, ROOT_FOLDER_ID, $name);
65 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Definition: AsyncNode.php:21

References Vendor\Package\$e, $name, $ref_id, getRefIdFromName(), and ROOT_FOLDER_ID.

+ Here is the call graph for this function:

◆ getChildren()

ilDAVClientNode::getChildren ( )
Returns
ilObject[]

Definition at line 70 of file class.ilDAVClientNode.php.

70 : array
71 {
72 return $this->getChildrenByParentRefId($this->repository_helper, $this->dav_factory, ROOT_FOLDER_ID);
73 }

References ROOT_FOLDER_ID.

◆ getLastModified()

ilDAVClientNode::getLastModified ( )

Definition at line 86 of file class.ilDAVClientNode.php.

86 : int
87 {
88 return strtotime('2000-01-01');
89 }

◆ getName()

ilDAVClientNode::getName ( )

Definition at line 50 of file class.ilDAVClientNode.php.

50 : string
51 {
52 return $this->client_name;
53 }

References $client_name.

◆ getRefIdFromName()

ilDAVClientNode::getRefIdFromName ( string  $name)
protected

Definition at line 91 of file class.ilDAVClientNode.php.

91 : int
92 {
93 $ref_parts = explode('_', $name);
94 if (count($ref_parts) == 2 && ($ref_id = (int) $ref_parts[1]) > 0) {
95 return $ref_id;
96 }
97
98 throw new NotFound("No id found for $name");
99 }

References $name, and $ref_id.

Referenced by childExists(), and getChild().

+ Here is the caller graph for this function:

Field Documentation

◆ $client_name

string ilDAVClientNode::$client_name
protected

Definition at line 36 of file class.ilDAVClientNode.php.

Referenced by __construct(), and getName().

◆ $dav_factory

ilWebDAVObjFactory ilDAVClientNode::$dav_factory
protected

Definition at line 34 of file class.ilDAVClientNode.php.

Referenced by __construct().

◆ $name_of_repository_root

string ilDAVClientNode::$name_of_repository_root
protected

Definition at line 37 of file class.ilDAVClientNode.php.

◆ $repository_helper

ilWebDAVRepositoryHelper ilDAVClientNode::$repository_helper
protected

Definition at line 35 of file class.ilDAVClientNode.php.

Referenced by __construct().


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