ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilSurveyCategory Class Reference

Survey category class. More...

+ Collaboration diagram for ilSurveyCategory:

Public Member Functions

 __construct ($title=null, $other=0, $neutral=0, $label=null, $scale=null)
 ilSurveyPhrases constructor More...
 
 __get ($value)
 Object getter. More...
 
 __set ($key, $value)
 Object setter. More...
 

Private Attributes

 $arrData
 

Detailed Description

Survey category class.

The ilSurveyCategory class encapsules a survey category

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

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

Constructor & Destructor Documentation

◆ __construct()

ilSurveyCategory::__construct (   $title = null,
  $other = 0,
  $neutral = 0,
  $label = null,
  $scale = null 
)

ilSurveyPhrases constructor

Definition at line 40 of file class.ilSurveyCategory.php.

41 {
42 $this->arrData = array(
43 "title" => $title,
44 "other" => $other,
45 "neutral" => $neutral,
46 "label" => $label,
47 "scale" => $scale
48 );
49 }

References $title.

Member Function Documentation

◆ __get()

ilSurveyCategory::__get (   $value)

Object getter.

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

55 {
56 switch ($value)
57 {
58 case 'other':
59 case 'neutral':
60 return ($this->arrData[$value]) ? 1 : 0;
61 break;
62 default:
63 if (array_key_exists($value, $this->arrData))
64 {
65 return $this->arrData[$value];
66 }
67 else
68 {
69 return null;
70 }
71 break;
72 }
73 }

◆ __set()

ilSurveyCategory::__set (   $key,
  $value 
)

Object setter.

Definition at line 78 of file class.ilSurveyCategory.php.

79 {
80 switch ($key)
81 {
82 default:
83 $this->arrData[$key] = $value;
84 break;
85 }
86 }

Field Documentation

◆ $arrData

ilSurveyCategory::$arrData
private

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


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