ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilAppointmentSessionFileHandler Class Reference

Session appointment file handler. More...

+ Inheritance diagram for ilAppointmentSessionFileHandler:
+ Collaboration diagram for ilAppointmentSessionFileHandler:

Public Member Functions

 getFiles ()
 Get files (for appointment) More...
 
- Public Member Functions inherited from ilAppointmentBaseFileHandler
 __construct ($a_appointment)
 Constructor. More...
 
 getCatId ($a_entry_id)
 
 getCatInfo ()
 

Additional Inherited Members

- Static Public Member Functions inherited from ilAppointmentBaseFileHandler
static getInstance ($a_appointment)
 Get instance. More...
 
- Protected Attributes inherited from ilAppointmentBaseFileHandler
 $appointment
 

Detailed Description

Session appointment file handler.

Author
Alex Killing killi.nosp@m.ng@l.nosp@m.eifos.nosp@m..de

Definition at line 14 of file class.ilAppointmentSessionFileHandler.php.

Member Function Documentation

◆ getFiles()

ilAppointmentSessionFileHandler::getFiles ( )

Get files (for appointment)

Parameters

Implements ilAppointmentFileHandler.

Definition at line 22 of file class.ilAppointmentSessionFileHandler.php.

References $filename, $files, ilAppointmentBaseFileHandler\getCatInfo(), and ilObjectActivation\getItemsByEvent().

23  {
24  $cat_info = $this->getCatInfo();
25 
26  //$session_obj = new ilObjSession($cat_info['obj_id'],false);
27 
28  include_once("./Services/Object/classes/class.ilObjectActivation.php");
29  $eventItems = ilObjectActivation::getItemsByEvent($cat_info['obj_id']);
30  $files = array();
31  if (count($eventItems)) {
32  foreach ($eventItems as $obj) {
33  if ($obj["type"] == "file") {
34  if ($this->access->checkAccessOfUser($this->user->getId(), "read", "", $obj['ref_id'])) {
35  $file = new ilObjFile($obj['ref_id']);
36 
37  // todo: this should be provided by an interface of ilObjFile
38  // currently this is copy/paste code from ilObjFile->sendFile
39  $filename = $file->getDirectory($file->getVersion()) . "/" . $file->getFileName();
40  if (@!is_file($filename)) {
41  $filename = $file->getDirectory() . "/" . $file->getFileName();
42  }
43  $files[] = $filename;
44  }
45  }
46  }
47  }
48  return $files;
49  }
$files
Definition: metarefresh.php:49
static getItemsByEvent($a_event_id)
Get session material / event items.
$filename
Definition: buildRTE.php:89
+ Here is the call graph for this function:

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