ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilSurveyMaterial Class Reference

Survey material class. More...

+ Collaboration diagram for ilSurveyMaterial:

Public Member Functions

 __construct ()
 ilSurveyMaterial constructor More...
 
 __set ($name, $value)
 
 __get ($name)
 

Data Fields

const MATERIAL_TYPE_INTERNALLINK = 0
 
const MATERIAL_TYPE_URL = 1
 
const MATERIAL_TYPE_FILE = 2
 

Protected Attributes

 $data
 

Detailed Description

Survey material class.

Author
Helmut Schottmüller ilias.nosp@m.@aur.nosp@m.ealis.nosp@m..de
Version
$Id$

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

Constructor & Destructor Documentation

◆ __construct()

ilSurveyMaterial::__construct ( )

ilSurveyMaterial constructor

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

References array, and data.

43  {
44  $this->data = array(
45  'type' => self::MATERIAL_TYPE_INTERNALLINK,
46  'internal_link' => '',
47  'title' => '',
48  'url' => '',
49  'filename' => ''
50  );
51  }
Add some data
Create styles array
The data for the language used.

Member Function Documentation

◆ __get()

ilSurveyMaterial::__get (   $name)

Definition at line 58 of file class.ilSurveyMaterial.php.

References $name, and data.

59  {
60  if (array_key_exists($name, $this->data)) {
61  switch ($name) {
62  case 'internal_link':
63  case 'import_id':
64  case 'material_title':
65  case 'text_material':
66  case 'file_material':
67  case 'external_link':
68  return (strlen($this->data[$name])) ? $this->data[$name] : null;
69  break;
70  default:
71  return $this->data[$name];
72  }
73  }
74  return null;
75  }
Add some data
if($format !==null) $name
Definition: metadata.php:146

◆ __set()

ilSurveyMaterial::__set (   $name,
  $value 
)

Definition at line 53 of file class.ilSurveyMaterial.php.

References $name, and data.

54  {
55  $this->data[$name] = $value;
56  }
Add some data
if($format !==null) $name
Definition: metadata.php:146

Field Documentation

◆ $data

ilSurveyMaterial::$data
protected

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

◆ MATERIAL_TYPE_FILE

const ilSurveyMaterial::MATERIAL_TYPE_FILE = 2

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

◆ MATERIAL_TYPE_INTERNALLINK

const ilSurveyMaterial::MATERIAL_TYPE_INTERNALLINK = 0

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

◆ MATERIAL_TYPE_URL

const ilSurveyMaterial::MATERIAL_TYPE_URL = 1

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


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