ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilCloudPlugin Class Reference

Class ilCloudPlugin. More...

+ Collaboration diagram for ilCloudPlugin:

Public Member Functions

 __construct ($service_name, $obj_id, $cloud_modul_object=null)
 
 setObjId ($obj_id)
 
 getObjId ()
 
 getPluginHookObject ()
 
 getAdminConfigObject ()
 
 setPluginHookObject ($plugin_hook_object)
 
 getTableName ()
 
 setMaxFileSize ($max_file_size)
 
 getMaxFileSize ()
 
 setCloudModulObject ($cloud_modul_object)
 
 getCloudModulObject ()
 
 getOwnerId ()
 $return integer More...
 
 read ()
 
 create ()
 
 doUpdate ()
 
 doDelete ()
 

Protected Attributes

 $obj_id
 
 $plugin_hook_object
 
 $table_name = ""
 
 $admin_config_object
 
 $cloud_modul_object
 
 $max_file_size = 25
 

Detailed Description

Class ilCloudPlugin.

Base Class for the model of the plugin. Probably will be extended by most plugins.

Author
Timon Amstutz timon.nosp@m..ams.nosp@m.tutz@.nosp@m.ilub.nosp@m..unib.nosp@m.e.ch
Version
$Id$

Definition at line 17 of file class.ilCloudPlugin.php.

Constructor & Destructor Documentation

◆ __construct()

ilCloudPlugin::__construct (   $service_name,
  $obj_id,
  $cloud_modul_object = null 
)
Parameters
$obj_id

Definition at line 52 of file class.ilCloudPlugin.php.

References $cloud_modul_object, $obj_id, ilObject2\_exists(), create(), ilCloudConnector\getPluginHookClass(), ilCloudException\PLUGIN_HOOK_COULD_NOT_BE_INSTANTIATED, read(), setCloudModulObject(), and setObjId().

53  {
54  $this->setObjId($obj_id);
55 
56  $this->plugin_hook_object = ilCloudConnector::getPluginHookClass($service_name);
57  if (!is_object($this->plugin_hook_object)) {
59  }
60  $this->admin_config_object = new ilCloudPluginConfig($this->plugin_hook_object->getPluginConfigTableName());
61  if (!$this->read()) {
62  $this->create();
63  }
64 
65  if (!$cloud_modul_object) {
66  // in the context of deleting, it's possible that the ilObjCloud with this obj_id is already pushing up the daisies
67  // so instantiating it would lead to an error
68  if ($obj_id == 0 || ilObjCloud::_exists($obj_id, false, 'cld')) {
70  }
71  }
73  }
setCloudModulObject($cloud_modul_object)
Class ilCloudPluginConfig.
static getPluginHookClass($service_name)
static _exists($a_id, $a_reference=false, $a_type=null)
Class ilObjCloud.
Class ilCloudException.
+ Here is the call graph for this function:

Member Function Documentation

◆ create()

ilCloudPlugin::create ( )

Definition at line 200 of file class.ilCloudPlugin.php.

Referenced by __construct().

201  {
202  }
+ Here is the caller graph for this function:

◆ doDelete()

ilCloudPlugin::doDelete ( )

Definition at line 210 of file class.ilCloudPlugin.php.

211  {
212  }

◆ doUpdate()

ilCloudPlugin::doUpdate ( )

Definition at line 205 of file class.ilCloudPlugin.php.

206  {
207  }

◆ getAdminConfigObject()

ilCloudPlugin::getAdminConfigObject ( )
Returns

Definition at line 106 of file class.ilCloudPlugin.php.

References $admin_config_object.

107  {
109  }

◆ getCloudModulObject()

ilCloudPlugin::getCloudModulObject ( )
Returns
ilObjCloud

Definition at line 177 of file class.ilCloudPlugin.php.

References $cloud_modul_object.

178  {
180  }

◆ getMaxFileSize()

ilCloudPlugin::getMaxFileSize ( )
Returns
int

Definition at line 159 of file class.ilCloudPlugin.php.

References $max_file_size.

160  {
161  return $this->max_file_size;
162  }

◆ getObjId()

ilCloudPlugin::getObjId ( )
Returns

Definition at line 88 of file class.ilCloudPlugin.php.

References $obj_id.

Referenced by getOwnerId().

89  {
90  return $this->obj_id;
91  }
+ Here is the caller graph for this function:

◆ getOwnerId()

ilCloudPlugin::getOwnerId ( )

$return integer

Definition at line 186 of file class.ilCloudPlugin.php.

References getObjId().

187  {
188  include_once("./Modules/Cloud/classes/class.ilObjCloud.php");
189  $cloud_object = new ilObjCloud($this->getObjId(), false);
190 
191  return $cloud_object->getOwnerId();
192  }
Class ilObjCloud.
+ Here is the call graph for this function:

◆ getPluginHookObject()

ilCloudPlugin::getPluginHookObject ( )
Returns

Definition at line 97 of file class.ilCloudPlugin.php.

References $plugin_hook_object.

Referenced by getTableName().

98  {
100  }
+ Here is the caller graph for this function:

◆ getTableName()

ilCloudPlugin::getTableName ( )
Returns
string

Definition at line 124 of file class.ilCloudPlugin.php.

References getPluginHookObject().

125  {
126  return $this->getPluginHookObject()->getPluginTableName();
127  }
+ Here is the call graph for this function:

◆ read()

ilCloudPlugin::read ( )

Definition at line 195 of file class.ilCloudPlugin.php.

Referenced by __construct().

196  {
197  }
+ Here is the caller graph for this function:

◆ setCloudModulObject()

ilCloudPlugin::setCloudModulObject (   $cloud_modul_object)
Parameters
$cloud_modul_object

Definition at line 168 of file class.ilCloudPlugin.php.

References $cloud_modul_object.

Referenced by __construct().

169  {
170  $this->cloud_modul_object = $cloud_modul_object;
171  }
+ Here is the caller graph for this function:

◆ setMaxFileSize()

ilCloudPlugin::setMaxFileSize (   $max_file_size)
Parameters
boolean$async_drawingpublic function setAsyncDrawing($async_drawing) { $this->async_drawing = $async_drawing; }

/**

Returns
boolean

public function getAsyncDrawing() { return $this->async_drawing; }

Parameters
int$max_file_size

Definition at line 150 of file class.ilCloudPlugin.php.

References $max_file_size.

151  {
152  $this->max_file_size = $max_file_size;
153  }

◆ setObjId()

ilCloudPlugin::setObjId (   $obj_id)
Parameters
$obj_id

Definition at line 79 of file class.ilCloudPlugin.php.

References $obj_id.

Referenced by __construct().

80  {
81  $this->obj_id = $obj_id;
82  }
+ Here is the caller graph for this function:

◆ setPluginHookObject()

ilCloudPlugin::setPluginHookObject (   $plugin_hook_object)
Parameters
\ilCloudHookPlugin$plugin_hook_object

Definition at line 115 of file class.ilCloudPlugin.php.

References $plugin_hook_object.

116  {
117  $this->plugin_hook_object = $plugin_hook_object;
118  }

Field Documentation

◆ $admin_config_object

ilCloudPlugin::$admin_config_object
protected

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

Referenced by getAdminConfigObject().

◆ $cloud_modul_object

ilCloudPlugin::$cloud_modul_object
protected

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

Referenced by __construct(), getCloudModulObject(), and setCloudModulObject().

◆ $max_file_size

ilCloudPlugin::$max_file_size = 25
protected

Definition at line 43 of file class.ilCloudPlugin.php.

Referenced by getMaxFileSize(), and setMaxFileSize().

◆ $obj_id

ilCloudPlugin::$obj_id
protected

Definition at line 23 of file class.ilCloudPlugin.php.

Referenced by __construct(), getObjId(), and setObjId().

◆ $plugin_hook_object

ilCloudPlugin::$plugin_hook_object
protected

Definition at line 27 of file class.ilCloudPlugin.php.

Referenced by getPluginHookObject(), and setPluginHookObject().

◆ $table_name

ilCloudPlugin::$table_name = ""
protected

Definition at line 31 of file class.ilCloudPlugin.php.


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