ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilMDTechnical Class Reference
+ Inheritance diagram for ilMDTechnical:
+ Collaboration diagram for ilMDTechnical:

Public Member Functions

 getPossibleSubelements ()
 
getFormatIds ()
 
getFormat ($a_format_id)
 
addFormat ()
 
getLocationIds ()
 
getLocation ($a_location_id)
 
addLocation ()
 
getRequirementIds ()
 
getRequirement ($a_requirement_id)
 
addRequirement ()
 
getOrCompositeIds ()
 
getOrComposite ($a_or_composite_id)
 
addOrComposite ()
 
 setSize ($a_size)
 
 getSize ()
 
 setInstallationRemarks ($a_val)
 
 getInstallationRemarks ()
 
 setInstallationRemarksLanguage (&$lng_obj)
 
getInstallationRemarksLanguage ()
 
 getInstallationRemarksLanguageCode ()
 
 setOtherPlatformRequirements ($a_val)
 
 getOtherPlatformRequirements ()
 
 setOtherPlatformRequirementsLanguage (&$lng_obj)
 
getOtherPlatformRequirementsLanguage ()
 
 getOtherPlatformRequirementsLanguageCode ()
 
 setDuration ($a_val)
 
 getDuration ()
 
 save ()
 
 update ()
 
 delete ()
 
 __getFields ()
 
 read ()
 
 toXML (&$writer)
 
getFormatIds ()
 
getFormat ($a_format_id)
 
addFormat ()
 
getLocationIds ()
 
getLocation ($a_location_id)
 
addLocation ()
 
getRequirementIds ()
 
getRequirement ($a_requirement_id)
 
addRequirement ()
 
getOrCompositeIds ()
 
getOrComposite ($a_or_composite_id)
 
addOrComposite ()
 
 setSize ($a_size)
 
 getSize ()
 
 setInstallationRemarks ($a_val)
 
 getInstallationRemarks ()
 
 setInstallationRemarksLanguage (&$lng_obj)
 
getInstallationRemarksLanguage ()
 
 getInstallationRemarksLanguageCode ()
 
 setOtherPlatformRequirements ($a_val)
 
 getOtherPlatformRequirements ()
 
 setOtherPlatformRequirementsLanguage (&$lng_obj)
 
getOtherPlatformRequirementsLanguage ()
 
 getOtherPlatformRequirementsLanguageCode ()
 
 setDuration ($a_val)
 
 getDuration ()
 
 save ()
 
 update ()
 
 delete ()
 
 __getFields ()
 
 read ()
 
 toXML (&$writer)
 
 _getId ($a_rbac_id, $a_obj_id)
 
- Public Member Functions inherited from ilMDBase
 __construct ( $a_rbac_id=0, $a_obj_id=0, $a_type=0)
 
 setRBACId ($a_id)
 
 getRBACId ()
 
 setObjId ($a_id)
 
 getObjId ()
 
 setObjType ($a_type)
 
 getObjType ()
 
 setMetaId ($a_meta_id, $a_read_data=true)
 
 getMetaId ()
 
 setParentType ($a_parent_type)
 
 getParentType ()
 
 setParentId ($a_id)
 
 getParentId ()
 
 setExportMode ($a_export_mode=true)
 
 getExportMode ()
 
 validate ()
 
 update ()
 
 save ()
 
 delete ()
 
 toXML (&$writer)
 
 __construct ( $a_rbac_id=0, $a_obj_id=0, $a_type=0)
 
 setRBACId ($a_id)
 
 getRBACId ()
 
 setObjId ($a_id)
 
 getObjId ()
 
 setObjType ($a_type)
 
 getObjType ()
 
 setMetaId ($a_meta_id, $a_read_data=true)
 
 getMetaId ()
 
 setParentType ($a_parent_type)
 
 getParentType ()
 
 setParentId ($a_id)
 
 getParentId ()
 
 validate ()
 
 update ()
 
 save ()
 
 delete ()
 
 toXML (&$writer)
 

Static Public Member Functions

static _getId ($a_rbac_id, $a_obj_id)
 

Additional Inherited Members

- Data Fields inherited from ilMDBase
 $rbac_id
 
 $obj_id
 
 $obj_type
 
 $export_mode = false
 
- Protected Attributes inherited from ilMDBase
 $log
 

Detailed Description

Definition at line 33 of file class.ilMDTechnical.php.

Member Function Documentation

◆ __getFields() [1/2]

ilMDTechnical::__getFields ( )

Definition at line 281 of file class.ilMDTechnical.php.

References array, getDuration(), getInstallationRemarks(), getInstallationRemarksLanguageCode(), ilMDBase\getObjId(), ilMDBase\getObjType(), getOtherPlatformRequirements(), getOtherPlatformRequirementsLanguageCode(), ilMDBase\getRBACId(), getSize(), and ilUtil\prepareDBString().

282  {
283  return array('rbac_id' => $this->getRBACId(),
284  'obj_id' => $this->getObjId(),
285  'obj_type' => ilUtil::prepareDBString($this->getObjType()),
286  'size' => ilUtil::prepareDBString($this->getSize()),
287  'installation_remarks' => ilUtil::prepareDBString($this->getInstallationRemarks()),
288  'installation_remarks_language' => ilUtil::prepareDBString($this->getInstallationRemarksLanguageCode()),
289  'other_platform_requirements' => ilUtil::prepareDBString($this->getOtherPlatformRequirements()),
290  'other_platform_requirements_language' => ilUtil::prepareDBString($this->getOtherPlatformRequirementsLanguageCode()),
291  'duration' => ilUtil::prepareDBString($this->getDuration()));
292  }
getOtherPlatformRequirementsLanguageCode()
Create styles array
The data for the language used.
static prepareDBString($a_str)
prepare a string for db writing (insert/update)
+ Here is the call graph for this function:

◆ __getFields() [2/2]

ilMDTechnical::__getFields ( )

Definition at line 292 of file class.ilMDTechnical.php.

References array, getDuration(), getInstallationRemarks(), getInstallationRemarksLanguageCode(), ilMDBase\getObjId(), ilMDBase\getObjType(), getOtherPlatformRequirements(), getOtherPlatformRequirementsLanguageCode(), ilMDBase\getRBACId(), and getSize().

Referenced by save().

293  {
294  return array('rbac_id' => array('integer',$this->getRBACId()),
295  'obj_id' => array('integer',$this->getObjId()),
296  'obj_type' => array('text',$this->getObjType()),
297  't_size' => array('text',$this->getSize()),
298  'ir' => array('text',$this->getInstallationRemarks()),
299  'ir_language' => array('text',$this->getInstallationRemarksLanguageCode()),
300  'opr' => array('text',$this->getOtherPlatformRequirements()),
301  'opr_language' => array('text',$this->getOtherPlatformRequirementsLanguageCode()),
302  'duration' => array('text',$this->getDuration()));
303  }
getOtherPlatformRequirementsLanguageCode()
Create styles array
The data for the language used.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ _getId() [1/2]

ilMDTechnical::_getId (   $a_rbac_id,
  $a_obj_id 
)

Definition at line 385 of file class.ilMDTechnical.php.

References $ilDB, $query, $res, $row, and ilDBConstants\FETCHMODE_OBJECT.

386  {
387  global $ilDB;
388 
389  $query = "SELECT meta_technical_id FROM il_meta_technical " .
390  "WHERE rbac_id = " . $ilDB->quote($a_rbac_id) . " " .
391  "AND obj_id = " . $ilDB->quote($a_obj_id);
392 
393  $res = $ilDB->query($query);
394  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
395  return $row->meta_technical_id;
396  }
397  return false;
398  }
foreach($_POST as $key=> $value) $res
$query
global $ilDB

◆ _getId() [2/2]

static ilMDTechnical::_getId (   $a_rbac_id,
  $a_obj_id 
)
static

Definition at line 399 of file class.ilMDTechnical.php.

References $ilDB, $query, $res, $row, and ilDBConstants\FETCHMODE_OBJECT.

Referenced by ilMD\getTechnical().

400  {
401  global $ilDB;
402 
403  $query = "SELECT meta_technical_id FROM il_meta_technical " .
404  "WHERE rbac_id = " . $ilDB->quote($a_rbac_id, 'integer') . " " .
405  "AND obj_id = " . $ilDB->quote($a_obj_id, 'integer');
406 
407  $res = $ilDB->query($query);
408  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
409  return $row->meta_technical_id;
410  }
411  return false;
412  }
foreach($_POST as $key=> $value) $res
$query
global $ilDB
+ Here is the caller graph for this function:

◆ addFormat() [1/2]

& ilMDTechnical::addFormat ( )

Definition at line 54 of file class.ilMDTechnical.php.

References ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

55  {
56  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDFormat.php';
57 
58  $for = new ilMDFormat($this->getRBACId(), $this->getObjId(), $this->getObjType());
59 
60  return $for;
61  }
+ Here is the call graph for this function:

◆ addFormat() [2/2]

& ilMDTechnical::addFormat ( )

Definition at line 68 of file class.ilMDTechnical.php.

References ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

69  {
70  include_once 'Services/MetaData/classes/class.ilMDFormat.php';
71 
72  $for = new ilMDFormat($this->getRBACId(), $this->getObjId(), $this->getObjType());
73 
74  return $for;
75  }
+ Here is the call graph for this function:

◆ addLocation() [1/2]

& ilMDTechnical::addLocation ( )

Definition at line 80 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

81  {
82  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLocation.php';
83 
84  $loc = new ilMDLocation($this->getRBACId(), $this->getObjId(), $this->getObjType());
85  $loc->setParentId($this->getMetaId());
86  $loc->setParentType('meta_technical');
87 
88  return $loc;
89  }
+ Here is the call graph for this function:

◆ addLocation() [2/2]

& ilMDTechnical::addLocation ( )

Definition at line 94 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

95  {
96  include_once 'Services/MetaData/classes/class.ilMDLocation.php';
97 
98  $loc = new ilMDLocation($this->getRBACId(), $this->getObjId(), $this->getObjType());
99  $loc->setParentId($this->getMetaId());
100  $loc->setParentType('meta_technical');
101 
102  return $loc;
103  }
+ Here is the call graph for this function:

◆ addOrComposite() [1/2]

& ilMDTechnical::addOrComposite ( )

Definition at line 138 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

139  {
140  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDOrComposite.php';
141 
142  $orc = new ilMDOrComposite($this->getRBACId(), $this->getObjId(), $this->getObjType());
143  $orc->setParentId($this->getMetaId());
144  $orc->setParentType('meta_technical');
145 
146  return $orc;
147  }
+ Here is the call graph for this function:

◆ addOrComposite() [2/2]

& ilMDTechnical::addOrComposite ( )

Definition at line 152 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

153  {
154  include_once 'Services/MetaData/classes/class.ilMDOrComposite.php';
155 
156  $orc = new ilMDOrComposite($this->getRBACId(), $this->getObjId(), $this->getObjType());
157  $orc->setParentId($this->getMetaId());
158  $orc->setParentType('meta_technical');
159 
160  return $orc;
161  }
+ Here is the call graph for this function:

◆ addRequirement() [1/2]

& ilMDTechnical::addRequirement ( )

Definition at line 108 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

109  {
110  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDRequirement.php';
111 
112  $rec = new ilMDRequirement($this->getRBACId(), $this->getObjId(), $this->getObjType());
113  $rec->setParentId($this->getMetaId());
114  $rec->setParentType('meta_technical');
115 
116  return $rec;
117  }
+ Here is the call graph for this function:

◆ addRequirement() [2/2]

& ilMDTechnical::addRequirement ( )

Definition at line 122 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

123  {
124  include_once 'Services/MetaData/classes/class.ilMDRequirement.php';
125 
126  $rec = new ilMDRequirement($this->getRBACId(), $this->getObjId(), $this->getObjType());
127  $rec->setParentId($this->getMetaId());
128  $rec->setParentType('meta_technical');
129 
130  return $rec;
131  }
+ Here is the call graph for this function:

◆ delete() [1/2]

ilMDTechnical::delete ( )

Definition at line 247 of file class.ilMDTechnical.php.

References $id, $ilDB, $query, $req, getFormat(), getFormatIds(), getLocation(), getLocationIds(), ilMDBase\getMetaId(), getOrComposite(), getOrCompositeIds(), getRequirement(), and getRequirementIds().

248  {
249  global $ilDB;
250 
251  if ($this->getMetaId()) {
252  $query = "DELETE FROM il_meta_technical " .
253  "WHERE meta_technical_id = " . $ilDB->quote($this->getMetaId());
254 
255  $this->db->query($query);
256 
257  foreach ($this->getFormatIds() as $id) {
258  $for =&$this->getFormat($id);
259  $for->delete();
260  }
261 
262  foreach ($this->getLocationIds() as $id) {
263  $loc =&$this->getLocation($id);
264  $loc->delete();
265  }
266  foreach ($this->getRequirementIds() as $id) {
267  $req =&$this->getRequirement($id);
268  $req->delete();
269  }
270  foreach ($this->getOrCompositeIds() as $id) {
271  $orc =&$this->getOrComposite($id);
272  $orc->delete();
273  }
274 
275  return true;
276  }
277  return false;
278  }
if(!array_key_exists('StateId', $_REQUEST)) $id
& getLocation($a_location_id)
$req
Definition: getUserInfo.php:20
$query
& getRequirement($a_requirement_id)
global $ilDB
& getOrComposite($a_or_composite_id)
& getFormat($a_format_id)
+ Here is the call graph for this function:

◆ delete() [2/2]

ilMDTechnical::delete ( )

Definition at line 259 of file class.ilMDTechnical.php.

References $id, $ilDB, $query, $req, $res, getFormat(), getFormatIds(), getLocation(), getLocationIds(), ilMDBase\getMetaId(), getOrComposite(), getOrCompositeIds(), getRequirement(), and getRequirementIds().

260  {
261  global $ilDB;
262 
263  if ($this->getMetaId()) {
264  $query = "DELETE FROM il_meta_technical " .
265  "WHERE meta_technical_id = " . $ilDB->quote($this->getMetaId(), 'integer');
266  $res = $ilDB->manipulate($query);
267 
268  foreach ($this->getFormatIds() as $id) {
269  $for =&$this->getFormat($id);
270  $for->delete();
271  }
272 
273  foreach ($this->getLocationIds() as $id) {
274  $loc =&$this->getLocation($id);
275  $loc->delete();
276  }
277  foreach ($this->getRequirementIds() as $id) {
278  $req =&$this->getRequirement($id);
279  $req->delete();
280  }
281  foreach ($this->getOrCompositeIds() as $id) {
282  $orc =&$this->getOrComposite($id);
283  $orc->delete();
284  }
285 
286  return true;
287  }
288  return false;
289  }
if(!array_key_exists('StateId', $_REQUEST)) $id
& getLocation($a_location_id)
$req
Definition: getUserInfo.php:20
foreach($_POST as $key=> $value) $res
$query
& getRequirement($a_requirement_id)
global $ilDB
& getOrComposite($a_or_composite_id)
& getFormat($a_format_id)
+ Here is the call graph for this function:

◆ getDuration() [1/2]

ilMDTechnical::getDuration ( )

Definition at line 208 of file class.ilMDTechnical.php.

209  {
210  return $this->duration;
211  }

◆ getDuration() [2/2]

ilMDTechnical::getDuration ( )

Definition at line 222 of file class.ilMDTechnical.php.

Referenced by __getFields(), and toXML().

223  {
224  return $this->duration;
225  }
+ Here is the caller graph for this function:

◆ getFormat() [1/2]

& ilMDTechnical::getFormat (   $a_format_id)

Definition at line 42 of file class.ilMDTechnical.php.

43  {
44  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDFormat.php';
45 
46  if (!$a_format_id) {
47  return false;
48  }
49  $for = new ilMDFormat($this, $a_format_id);
50  $for->setMetaId($a_format_id);
51 
52  return $for;
53  }

◆ getFormat() [2/2]

& ilMDTechnical::getFormat (   $a_format_id)

Definition at line 56 of file class.ilMDTechnical.php.

Referenced by delete(), and toXML().

57  {
58  include_once 'Services/MetaData/classes/class.ilMDFormat.php';
59 
60  if (!$a_format_id) {
61  return false;
62  }
63  $for = new ilMDFormat($this, $a_format_id);
64  $for->setMetaId($a_format_id);
65 
66  return $for;
67  }
+ Here is the caller graph for this function:

◆ getFormatIds() [1/2]

& ilMDTechnical::getFormatIds ( )

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

References ilMDFormat\_getIds(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

37  {
38  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDFormat.php';
39 
40  return ilMDFormat::_getIds($this->getRBACId(), $this->getObjId());
41  }
static _getIds($a_rbac_id, $a_obj_id)
+ Here is the call graph for this function:

◆ getFormatIds() [2/2]

& ilMDTechnical::getFormatIds ( )

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

References ilMDFormat\_getIds(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

51  {
52  include_once 'Services/MetaData/classes/class.ilMDFormat.php';
53 
54  return ilMDFormat::_getIds($this->getRBACId(), $this->getObjId());
55  }
static _getIds($a_rbac_id, $a_obj_id)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getInstallationRemarks() [1/2]

ilMDTechnical::getInstallationRemarks ( )

Definition at line 162 of file class.ilMDTechnical.php.

163  {
164  return $this->installation_remarks;
165  }

◆ getInstallationRemarks() [2/2]

ilMDTechnical::getInstallationRemarks ( )

Definition at line 176 of file class.ilMDTechnical.php.

Referenced by __getFields(), and toXML().

177  {
178  return $this->installation_remarks;
179  }
+ Here is the caller graph for this function:

◆ getInstallationRemarksLanguage() [1/2]

& ilMDTechnical::getInstallationRemarksLanguage ( )

Definition at line 172 of file class.ilMDTechnical.php.

173  {
174  return is_object($this->installation_remarks_language) ? $this->installation_remarks_language : false;
175  }

◆ getInstallationRemarksLanguage() [2/2]

& ilMDTechnical::getInstallationRemarksLanguage ( )

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

187  {
188  return is_object($this->installation_remarks_language) ? $this->installation_remarks_language : false;
189  }

◆ getInstallationRemarksLanguageCode() [1/2]

ilMDTechnical::getInstallationRemarksLanguageCode ( )

Definition at line 176 of file class.ilMDTechnical.php.

177  {
178  return is_object($this->installation_remarks_language) ? $this->installation_remarks_language->getLanguageCode() : false;
179  }

◆ getInstallationRemarksLanguageCode() [2/2]

ilMDTechnical::getInstallationRemarksLanguageCode ( )

Definition at line 190 of file class.ilMDTechnical.php.

Referenced by __getFields(), and toXML().

191  {
192  return is_object($this->installation_remarks_language) ? $this->installation_remarks_language->getLanguageCode() : false;
193  }
+ Here is the caller graph for this function:

◆ getLocation() [1/2]

& ilMDTechnical::getLocation (   $a_location_id)

Definition at line 68 of file class.ilMDTechnical.php.

69  {
70  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLocation.php';
71 
72  if (!$a_location_id) {
73  return false;
74  }
75  $loc = new ilMDLocation();
76  $loc->setMetaId($a_location_id);
77 
78  return $loc;
79  }

◆ getLocation() [2/2]

& ilMDTechnical::getLocation (   $a_location_id)

Definition at line 82 of file class.ilMDTechnical.php.

Referenced by delete(), and toXML().

83  {
84  include_once 'Services/MetaData/classes/class.ilMDLocation.php';
85 
86  if (!$a_location_id) {
87  return false;
88  }
89  $loc = new ilMDLocation();
90  $loc->setMetaId($a_location_id);
91 
92  return $loc;
93  }
+ Here is the caller graph for this function:

◆ getLocationIds() [1/2]

& ilMDTechnical::getLocationIds ( )

Definition at line 62 of file class.ilMDTechnical.php.

References ilMDLocation\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

63  {
64  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLocation.php';
65 
66  return ilMDLocation::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
67  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:

◆ getLocationIds() [2/2]

& ilMDTechnical::getLocationIds ( )

Definition at line 76 of file class.ilMDTechnical.php.

References ilMDLocation\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

77  {
78  include_once 'Services/MetaData/classes/class.ilMDLocation.php';
79 
80  return ilMDLocation::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
81  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getOrComposite() [1/2]

& ilMDTechnical::getOrComposite (   $a_or_composite_id)

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

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

125  {
126  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDOrComposite.php';
127 
128  if (!$a_or_composite_id) {
129  return false;
130  }
131  $orc = new ilMDOrComposite($this->getRBACId(), $this->getObjId(), $this->getObjType());
132  $orc->setOrCompositeId($a_or_composite_id);
133  $orc->setParentId($this->getMetaId());
134  $orc->setParentType('meta_technical');
135 
136  return $orc;
137  }
+ Here is the call graph for this function:

◆ getOrComposite() [2/2]

& ilMDTechnical::getOrComposite (   $a_or_composite_id)

Definition at line 138 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilMDBase\getObjId(), ilMDBase\getObjType(), and ilMDBase\getRBACId().

Referenced by delete(), and toXML().

139  {
140  include_once 'Services/MetaData/classes/class.ilMDOrComposite.php';
141 
142  if (!$a_or_composite_id) {
143  return false;
144  }
145  $orc = new ilMDOrComposite($this->getRBACId(), $this->getObjId(), $this->getObjType());
146  $orc->setOrCompositeId($a_or_composite_id);
147  $orc->setParentId($this->getMetaId());
148  $orc->setParentType('meta_technical');
149 
150  return $orc;
151  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getOrCompositeIds() [1/2]

& ilMDTechnical::getOrCompositeIds ( )

Definition at line 118 of file class.ilMDTechnical.php.

References ilMDOrComposite\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

119  {
120  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDOrComposite.php';
121 
122  return ilMDOrComposite::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
123  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type, $a_or_composite_id=0)
+ Here is the call graph for this function:

◆ getOrCompositeIds() [2/2]

& ilMDTechnical::getOrCompositeIds ( )

Definition at line 132 of file class.ilMDTechnical.php.

References ilMDOrComposite\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), getPossibleSubelements(), and toXML().

133  {
134  include_once 'Services/MetaData/classes/class.ilMDOrComposite.php';
135 
136  return ilMDOrComposite::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
137  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type, $a_or_composite_id=0)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getOtherPlatformRequirements() [1/2]

ilMDTechnical::getOtherPlatformRequirements ( )

Definition at line 184 of file class.ilMDTechnical.php.

185  {
186  return $this->other_platform_requirements;
187  }

◆ getOtherPlatformRequirements() [2/2]

ilMDTechnical::getOtherPlatformRequirements ( )

Definition at line 198 of file class.ilMDTechnical.php.

Referenced by __getFields(), and toXML().

199  {
200  return $this->other_platform_requirements;
201  }
+ Here is the caller graph for this function:

◆ getOtherPlatformRequirementsLanguage() [1/2]

& ilMDTechnical::getOtherPlatformRequirementsLanguage ( )

Definition at line 194 of file class.ilMDTechnical.php.

195  {
196  return is_object($this->other_platform_requirements_language) ? $this->other_platform_requirements_language : false;
197  }

◆ getOtherPlatformRequirementsLanguage() [2/2]

& ilMDTechnical::getOtherPlatformRequirementsLanguage ( )

Definition at line 208 of file class.ilMDTechnical.php.

209  {
210  return is_object($this->other_platform_requirements_language) ? $this->other_platform_requirements_language : false;
211  }

◆ getOtherPlatformRequirementsLanguageCode() [1/2]

ilMDTechnical::getOtherPlatformRequirementsLanguageCode ( )

Definition at line 198 of file class.ilMDTechnical.php.

199  {
200  return is_object($this->other_platform_requirements_language)
201  ? $this->other_platform_requirements_language->getLanguageCode()
202  : false;
203  }

◆ getOtherPlatformRequirementsLanguageCode() [2/2]

ilMDTechnical::getOtherPlatformRequirementsLanguageCode ( )

Definition at line 212 of file class.ilMDTechnical.php.

Referenced by __getFields(), and toXML().

213  {
214  return is_object($this->other_platform_requirements_language)
215  ? $this->other_platform_requirements_language->getLanguageCode()
216  : false;
217  }
+ Here is the caller graph for this function:

◆ getPossibleSubelements()

ilMDTechnical::getPossibleSubelements ( )

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

References getOrCompositeIds(), and getRequirementIds().

36  {
37  $subs['Format'] = 'meta_format';
38  $subs['Location'] = 'meta_location';
39  if (!$this->getOrCompositeIds()) {
40  $subs['Requirement'] = 'meta_requirement';
41  }
42  if (!$this->getRequirementIds()) {
43  $subs['OrComposite'] = 'meta_or_composite';
44  }
45 
46  return $subs;
47  }
+ Here is the call graph for this function:

◆ getRequirement() [1/2]

& ilMDTechnical::getRequirement (   $a_requirement_id)

Definition at line 96 of file class.ilMDTechnical.php.

97  {
98  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDRequirement.php';
99 
100  if (!$a_requirement_id) {
101  return false;
102  }
103  $rec = new ilMDRequirement();
104  $rec->setMetaId($a_requirement_id);
105 
106  return $rec;
107  }

◆ getRequirement() [2/2]

& ilMDTechnical::getRequirement (   $a_requirement_id)

Definition at line 110 of file class.ilMDTechnical.php.

Referenced by delete(), and toXML().

111  {
112  include_once 'Services/MetaData/classes/class.ilMDRequirement.php';
113 
114  if (!$a_requirement_id) {
115  return false;
116  }
117  $rec = new ilMDRequirement();
118  $rec->setMetaId($a_requirement_id);
119 
120  return $rec;
121  }
+ Here is the caller graph for this function:

◆ getRequirementIds() [1/2]

& ilMDTechnical::getRequirementIds ( )

Definition at line 90 of file class.ilMDTechnical.php.

References ilMDRequirement\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

91  {
92  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDRequirement.php';
93 
94  return ilMDRequirement::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
95  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type, $a_or_composite_id=0)
+ Here is the call graph for this function:

◆ getRequirementIds() [2/2]

& ilMDTechnical::getRequirementIds ( )

Definition at line 104 of file class.ilMDTechnical.php.

References ilMDRequirement\_getIds(), ilMDBase\getMetaId(), ilMDBase\getObjId(), and ilMDBase\getRBACId().

Referenced by delete(), getPossibleSubelements(), and toXML().

105  {
106  include_once 'Services/MetaData/classes/class.ilMDRequirement.php';
107 
108  return ilMDRequirement::_getIds($this->getRBACId(), $this->getObjId(), $this->getMetaId(), 'meta_technical');
109  }
static _getIds($a_rbac_id, $a_obj_id, $a_parent_id, $a_parent_type, $a_or_composite_id=0)
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getSize() [1/2]

ilMDTechnical::getSize ( )

Definition at line 154 of file class.ilMDTechnical.php.

References $size.

155  {
156  return $this->size;
157  }
$size
Definition: RandomTest.php:84

◆ getSize() [2/2]

ilMDTechnical::getSize ( )

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

References $size.

Referenced by __getFields(), and toXML().

169  {
170  return $this->size;
171  }
$size
Definition: RandomTest.php:84
+ Here is the caller graph for this function:

◆ read() [1/2]

ilMDTechnical::read ( )

Definition at line 294 of file class.ilMDTechnical.php.

References $ilDB, $query, $res, $row, ilDBConstants\FETCHMODE_OBJECT, ilMDBase\getMetaId(), setDuration(), setInstallationRemarks(), setInstallationRemarksLanguage(), ilMDBase\setObjId(), ilMDBase\setObjType(), setOtherPlatformRequirements(), setOtherPlatformRequirementsLanguage(), ilMDBase\setRBACId(), setSize(), and ilUtil\stripSlashes().

295  {
296  global $ilDB;
297 
298  include_once 'Services/Migration/DBUpdate_426/classes/class.ilMDLanguageItem.php';
299 
300  if ($this->getMetaId()) {
301  $query = "SELECT * FROM il_meta_technical " .
302  "WHERE meta_technical_id = " . $ilDB->quote($this->getMetaId());
303 
304 
305  $res = $this->db->query($query);
306  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
307  $this->setRBACId($row->rbac_id);
308  $this->setObjId($row->obj_id);
309  $this->setObjType($row->obj_type);
310  $this->setSize(ilUtil::stripSlashes($row->size));
311  $this->setInstallationRemarks(ilUtil::stripSlashes($row->installation_remarks));
312  $this->setInstallationRemarksLanguage(new ilMDLanguageItem($row->installation_remarks_language));
313  $this->setOtherPlatformRequirements(ilUtil::stripSlashes($row->other_platform_requirements));
314  $this->setOtherPlatformRequirementsLanguage(new ilMDLanguageItem($row->other_platform_requirements_language));
315  $this->setDuration(ilUtil::stripSlashes($row->duration));
316  }
317  return true;
318  }
319  return false;
320  }
setOtherPlatformRequirementsLanguage(&$lng_obj)
setObjType($a_type)
foreach($_POST as $key=> $value) $res
setInstallationRemarks($a_val)
setObjId($a_id)
setRBACId($a_id)
$query
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
global $ilDB
setInstallationRemarksLanguage(&$lng_obj)
setOtherPlatformRequirements($a_val)
+ Here is the call graph for this function:

◆ read() [2/2]

ilMDTechnical::read ( )

Definition at line 305 of file class.ilMDTechnical.php.

References $ilDB, $query, $res, $row, ilDBConstants\FETCHMODE_OBJECT, ilMDBase\getMetaId(), setDuration(), setInstallationRemarks(), setInstallationRemarksLanguage(), ilMDBase\setObjId(), ilMDBase\setObjType(), setOtherPlatformRequirements(), setOtherPlatformRequirementsLanguage(), ilMDBase\setRBACId(), and setSize().

306  {
307  global $ilDB;
308 
309  include_once 'Services/MetaData/classes/class.ilMDLanguageItem.php';
310 
311  if ($this->getMetaId()) {
312  $query = "SELECT * FROM il_meta_technical " .
313  "WHERE meta_technical_id = " . $ilDB->quote($this->getMetaId(), 'integer') . " ";
314 
315  $res = $ilDB->query($query);
316  while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
317  $this->setRBACId($row->rbac_id);
318  $this->setObjId($row->obj_id);
319  $this->setObjType($row->obj_type);
320  $this->setSize($row->t_size);
321  $this->setInstallationRemarks($row->ir);
322  $this->setInstallationRemarksLanguage(new ilMDLanguageItem($row->ir_language));
323  $this->setOtherPlatformRequirements($row->opr);
325  $this->setDuration($row->duration);
326  }
327  return true;
328  }
329  return false;
330  }
setOtherPlatformRequirementsLanguage(&$lng_obj)
setObjType($a_type)
foreach($_POST as $key=> $value) $res
setInstallationRemarks($a_val)
setObjId($a_id)
setRBACId($a_id)
$query
global $ilDB
setInstallationRemarksLanguage(&$lng_obj)
setOtherPlatformRequirements($a_val)
+ Here is the call graph for this function:

◆ save() [1/2]

ilMDTechnical::save ( )

Definition at line 215 of file class.ilMDTechnical.php.

References ilMDBase\getMetaId(), ilDBConstants\MDB2_AUTOQUERY_INSERT, and ilMDBase\setMetaId().

216  {
217  if ($this->db->autoExecute(
218  'il_meta_technical',
219  $this->__getFields(),
221  )) {
222  $this->setMetaId($this->db->getLastInsertId());
223 
224  return $this->getMetaId();
225  }
226 
227  return false;
228  }
setMetaId($a_meta_id, $a_read_data=true)
+ Here is the call graph for this function:

◆ save() [2/2]

ilMDTechnical::save ( )

Definition at line 229 of file class.ilMDTechnical.php.

References $ilDB, __getFields(), array, ilMDBase\getMetaId(), and ilMDBase\setMetaId().

230  {
231  global $ilDB;
232 
233  $fields = $this->__getFields();
234  $fields['meta_technical_id'] = array('integer',$next_id = $ilDB->nextId('il_meta_technical'));
235 
236  if ($this->db->insert('il_meta_technical', $fields)) {
237  $this->setMetaId($next_id);
238  return $this->getMetaId();
239  }
240  return false;
241  }
setMetaId($a_meta_id, $a_read_data=true)
Create styles array
The data for the language used.
global $ilDB
+ Here is the call graph for this function:

◆ setDuration() [1/2]

ilMDTechnical::setDuration (   $a_val)

Definition at line 204 of file class.ilMDTechnical.php.

205  {
206  $this->duration = $a_val;
207  }

◆ setDuration() [2/2]

ilMDTechnical::setDuration (   $a_val)

Definition at line 218 of file class.ilMDTechnical.php.

Referenced by read().

219  {
220  $this->duration = $a_val;
221  }
+ Here is the caller graph for this function:

◆ setInstallationRemarks() [1/2]

ilMDTechnical::setInstallationRemarks (   $a_val)

Definition at line 158 of file class.ilMDTechnical.php.

159  {
160  $this->installation_remarks = $a_val;
161  }

◆ setInstallationRemarks() [2/2]

ilMDTechnical::setInstallationRemarks (   $a_val)

Definition at line 172 of file class.ilMDTechnical.php.

Referenced by read().

173  {
174  $this->installation_remarks = $a_val;
175  }
+ Here is the caller graph for this function:

◆ setInstallationRemarksLanguage() [1/2]

ilMDTechnical::setInstallationRemarksLanguage ( $lng_obj)

Definition at line 166 of file class.ilMDTechnical.php.

167  {
168  if (is_object($lng_obj)) {
169  $this->installation_remarks_language =&$lng_obj;
170  }
171  }

◆ setInstallationRemarksLanguage() [2/2]

ilMDTechnical::setInstallationRemarksLanguage ( $lng_obj)

Definition at line 180 of file class.ilMDTechnical.php.

Referenced by read().

181  {
182  if (is_object($lng_obj)) {
183  $this->installation_remarks_language =&$lng_obj;
184  }
185  }
+ Here is the caller graph for this function:

◆ setOtherPlatformRequirements() [1/2]

ilMDTechnical::setOtherPlatformRequirements (   $a_val)

Definition at line 180 of file class.ilMDTechnical.php.

181  {
182  $this->other_platform_requirements = $a_val;
183  }

◆ setOtherPlatformRequirements() [2/2]

ilMDTechnical::setOtherPlatformRequirements (   $a_val)

Definition at line 194 of file class.ilMDTechnical.php.

Referenced by read().

195  {
196  $this->other_platform_requirements = $a_val;
197  }
+ Here is the caller graph for this function:

◆ setOtherPlatformRequirementsLanguage() [1/2]

ilMDTechnical::setOtherPlatformRequirementsLanguage ( $lng_obj)

Definition at line 188 of file class.ilMDTechnical.php.

189  {
190  if (is_object($lng_obj)) {
191  $this->other_platform_requirements_language =&$lng_obj;
192  }
193  }

◆ setOtherPlatformRequirementsLanguage() [2/2]

ilMDTechnical::setOtherPlatformRequirementsLanguage ( $lng_obj)

Definition at line 202 of file class.ilMDTechnical.php.

Referenced by read().

203  {
204  if (is_object($lng_obj)) {
205  $this->other_platform_requirements_language =&$lng_obj;
206  }
207  }
+ Here is the caller graph for this function:

◆ setSize() [1/2]

ilMDTechnical::setSize (   $a_size)

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

References size.

151  {
152  $this->size = $a_size;
153  }
Set page orientation and size
Definition: 04printing.php:77

◆ setSize() [2/2]

ilMDTechnical::setSize (   $a_size)

Definition at line 164 of file class.ilMDTechnical.php.

References size.

Referenced by read().

165  {
166  $this->size = $a_size;
167  }
Set page orientation and size
Definition: 04printing.php:77
+ Here is the caller graph for this function:

◆ toXML() [1/2]

ilMDTechnical::toXML ( $writer)

Definition at line 327 of file class.ilMDTechnical.php.

References $id, $req, array, getDuration(), getFormat(), getFormatIds(), getInstallationRemarks(), getInstallationRemarksLanguageCode(), getLocation(), getLocationIds(), getOrComposite(), getOrCompositeIds(), getOtherPlatformRequirements(), getOtherPlatformRequirementsLanguageCode(), getRequirement(), getRequirementIds(), and getSize().

328  {
329  $writer->xmlStartTag('Technical');
330 
331  // Foramt
332  foreach ($this->getFormatIds() as $id) {
333  $for =&$this->getFormat($id);
334  $for->toXML($writer);
335  }
336 
337  // Size
338  if (strlen($this->getSize())) {
339  $writer->xmlElement('Size', null, $this->getSize());
340  }
341 
342  // Location
343  foreach ($this->getLocationIds() as $id) {
344  $loc =&$this->getLocation($id);
345  $loc->toXML($writer);
346  }
347 
348  // Requirement
349  foreach ($this->getRequirementIds() as $id) {
350  $req =&$this->getRequirement($id);
351  $req->toXML($writer);
352  }
353 
354  // OrComposite
355  foreach ($this->getOrCompositeIds() as $id) {
356  $orc =&$this->getOrComposite($id);
357  $orc->toXML($writer);
358  }
359 
360  // InstallationRemarks
361  if (strlen($this->getInstallationRemarks())) {
362  $writer->xmlElement(
363  'InstallationRemarks',
364  array('Language' => $this->getInstallationRemarksLanguageCode()),
365  $this->getInstallationRemarks()
366  );
367  }
368 
369  // OtherPlatformRequirements
370  if (strlen($this->getOtherPlatformRequirements())) {
371  $writer->xmlElement(
372  'OtherPlatformRequirements',
373  array('Language' => $this->getOtherPlatformRequirementsLanguageCode()),
375  );
376  }
377  // Durtation
378  if (strlen($this->getDuration())) {
379  $writer->xmlElement('Duration', null, $this->getDuration());
380  }
381 
382  $writer->xmlEndTag('Technical');
383  }
if(!array_key_exists('StateId', $_REQUEST)) $id
& getLocation($a_location_id)
getOtherPlatformRequirementsLanguageCode()
$req
Definition: getUserInfo.php:20
& getRequirement($a_requirement_id)
Create styles array
The data for the language used.
& getOrComposite($a_or_composite_id)
& getFormat($a_format_id)
+ Here is the call graph for this function:

◆ toXML() [2/2]

ilMDTechnical::toXML ( $writer)

Definition at line 337 of file class.ilMDTechnical.php.

References $id, $req, array, getDuration(), getFormat(), getFormatIds(), getInstallationRemarks(), getInstallationRemarksLanguageCode(), getLocation(), getLocationIds(), getOrComposite(), getOrCompositeIds(), getOtherPlatformRequirements(), getOtherPlatformRequirementsLanguageCode(), getRequirement(), getRequirementIds(), and getSize().

338  {
339  $writer->xmlStartTag('Technical');
340 
341  // Format
342  foreach ($this->getFormatIds() as $id) {
343  $for =&$this->getFormat($id);
344  $for->toXML($writer);
345  }
346 
347  // Size
348  if (strlen($this->getSize())) {
349  $writer->xmlElement('Size', null, $this->getSize());
350  }
351 
352  // Location
353  foreach ($this->getLocationIds() as $id) {
354  $loc =&$this->getLocation($id);
355  $loc->toXML($writer);
356  }
357 
358  // Requirement
359  foreach ($this->getRequirementIds() as $id) {
360  $req =&$this->getRequirement($id);
361  $req->toXML($writer);
362  }
363 
364  // OrComposite
365  foreach ($this->getOrCompositeIds() as $id) {
366  $orc =&$this->getOrComposite($id);
367  $orc->toXML($writer);
368  }
369 
370  // InstallationRemarks
371  if (strlen($this->getInstallationRemarks())) {
372  $writer->xmlElement(
373  'InstallationRemarks',
374  array('Language' => $this->getInstallationRemarksLanguageCode()
376  : 'en'),
377  $this->getInstallationRemarks()
378  );
379  }
380 
381  // OtherPlatformRequirements
382  if (strlen($this->getOtherPlatformRequirements())) {
383  $writer->xmlElement(
384  'OtherPlatformRequirements',
385  array('Language' => $this->getOtherPlatformRequirementsLanguageCode()
387  : 'en'),
389  );
390  }
391  // Duration
392  if (strlen($this->getDuration())) {
393  $writer->xmlElement('Duration', null, $this->getDuration());
394  }
395 
396  $writer->xmlEndTag('Technical');
397  }
if(!array_key_exists('StateId', $_REQUEST)) $id
& getLocation($a_location_id)
getOtherPlatformRequirementsLanguageCode()
$req
Definition: getUserInfo.php:20
& getRequirement($a_requirement_id)
Create styles array
The data for the language used.
& getOrComposite($a_or_composite_id)
& getFormat($a_format_id)
+ Here is the call graph for this function:

◆ update() [1/2]

ilMDTechnical::update ( )

Definition at line 230 of file class.ilMDTechnical.php.

References $ilDB, ilMDBase\getMetaId(), and ilDBConstants\MDB2_AUTOQUERY_UPDATE.

231  {
232  global $ilDB;
233 
234  if ($this->getMetaId()) {
235  if ($this->db->autoExecute(
236  'il_meta_technical',
237  $this->__getFields(),
239  "meta_technical_id = " . $ilDB->quote($this->getMetaId())
240  )) {
241  return true;
242  }
243  }
244  return false;
245  }
global $ilDB
+ Here is the call graph for this function:

◆ update() [2/2]

ilMDTechnical::update ( )

Definition at line 243 of file class.ilMDTechnical.php.

References $ilDB, array, and ilMDBase\getMetaId().

244  {
245  global $ilDB;
246 
247  if ($this->getMetaId()) {
248  if ($this->db->update(
249  'il_meta_technical',
250  $this->__getFields(),
251  array("meta_technical_id" => array('integer',$this->getMetaId()))
252  )) {
253  return true;
254  }
255  }
256  return false;
257  }
Create styles array
The data for the language used.
global $ilDB
+ Here is the call graph for this function:

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