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

Class ilChatroomAuthInputGUI. More...

+ Inheritance diagram for ilChatroomAuthInputGUI:
+ Collaboration diagram for ilChatroomAuthInputGUI:

Public Member Functions

 getCtrlPath ()
 
 setCtrlPath ($ctrl_path)
 
 setValueByArray (array $a_values)
 
 insert (ilTemplate $a_tpl)
 {} More...
 
 getSize ()
 
 setSize ($size)
 
- Public Member Functions inherited from ilSubEnabledFormPropertyGUI
 addSubItem ($a_item)
 Add Subitem. More...
 
 getSubItems ()
 Get Subitems. More...
 
 getSubInputItemsRecursive ()
 returns a flat array of possibly existing subitems recursively More...
 
 checkSubItemsInput ()
 Check SubItems. More...
 
 getSubForm ()
 Get sub form html. More...
 
 getItemByPostVar ($a_post_var)
 Get item by post var. More...
 
- Public Member Functions inherited from ilFormPropertyGUI
 __construct ($a_title="", $a_postvar="")
 Constructor. More...
 
 executeCommand ()
 Execute command. More...
 
 getType ()
 Get Type. More...
 
 setTitle ($a_title)
 Set Title. More...
 
 getTitle ()
 Get Title. More...
 
 setPostVar ($a_postvar)
 Set Post Variable. More...
 
 getPostVar ()
 Get Post Variable. More...
 
 getFieldId ()
 Get Post Variable. More...
 
 setInfo ($a_info)
 Set Information Text. More...
 
 getInfo ()
 Get Information Text. More...
 
 setAlert ($a_alert)
 Set Alert Text. More...
 
 getAlert ()
 Get Alert Text. More...
 
 setRequired ($a_required)
 Set Required. More...
 
 getRequired ()
 Get Required. More...
 
 setDisabled ($a_disabled)
 Set Disabled. More...
 
 getDisabled ()
 Get Disabled. More...
 
 checkInput ()
 Check input, strip slashes etc. More...
 
 setParentForm ($a_parentform)
 Set Parent Form. More...
 
 getParentForm ()
 Get Parent Form. More...
 
 setParent ($a_val)
 Set Parent GUI object. More...
 
 getParent ()
 Get Parent GUI object. More...
 
 getSubForm ()
 Get sub form html. More...
 
 hideSubForm ()
 Sub form hidden on init? More...
 
 setHiddenTitle ($a_val)
 Set hidden title (for screenreaders) More...
 
 getHiddenTitle ()
 Get hidden title. More...
 
 getItemByPostVar ($a_post_var)
 Get item by post var. More...
 
 serializeData ()
 serialize data More...
 
 unserializeData ($a_data)
 unserialize data More...
 
 writeToSession ()
 Write to session. More...
 
 clearFromSession ()
 Clear session value. More...
 
 readFromSession ()
 Read from session. More...
 
 getHiddenTag ($a_post_var, $a_value)
 Get hidden tag (used for disabled properties) More...
 
 setMulti ($a_multi, $a_sortable=false, $a_addremove=true)
 Set Multi. More...
 
 getMulti ()
 Get Multi. More...
 
 setMultiValues (array $a_values)
 Set multi values. More...
 
 getMultiValues ()
 Get multi values. More...
 
 getContentOutsideFormTag ()
 Get content that has to reside outside of the parent form tag, e.g. More...
 
 stripSlashesAddSpaceFallback ($a_str)
 Strip slashes with add space fallback, see https://www.ilias.de/mantis/view.php?id=19727. More...
 

Data Fields

const NAME_AUTH_PROP_1 = 'key'
 
const NAME_AUTH_PROP_2 = 'secret'
 

Protected Member Functions

 getRandomValues ()
 
- Protected Member Functions inherited from ilFormPropertyGUI
 setType ($a_type)
 Set Type. More...
 
 getMultiIconsHTML ()
 Get HTML for multiple value icons. More...
 

Protected Attributes

 $ctrl_path = array()
 
 $size = 10
 
 $values
 
- Protected Attributes inherited from ilSubEnabledFormPropertyGUI
 $sub_items = array()
 
- Protected Attributes inherited from ilFormPropertyGUI
 $type
 
 $title
 
 $postvar
 
 $info
 
 $alert
 
 $required = false
 
 $parentgui
 
 $parentform
 
 $hidden_title = ""
 
 $multi = false
 
 $multi_sortable = false
 
 $multi_addremove = true
 
 $multi_values
 

Private Member Functions

 uuidV4 ()
 Generates a pseudo random string following the RFC 4122. More...
 

Additional Inherited Members

- Static Public Member Functions inherited from ilFormPropertyGUI
static removeProhibitedCharacters ($a_text)
 Remove prohibited characters see #19159. More...
 

Detailed Description

Member Function Documentation

◆ getCtrlPath()

ilChatroomAuthInputGUI::getCtrlPath ( )
Returns
array

Definition at line 72 of file class.ilChatroomAuthInputGUI.php.

◆ getRandomValues()

ilChatroomAuthInputGUI::getRandomValues ( )
protected

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

36 {
37 $response = new stdClass();
38
39 $response->{self::NAME_AUTH_PROP_1} = $this->uuidV4();
40 $response->{self::NAME_AUTH_PROP_2} = $this->uuidV4();
41
42 echo json_encode($response);
43 exit();
44 }
uuidV4()
Generates a pseudo random string following the RFC 4122.

◆ getSize()

ilChatroomAuthInputGUI::getSize ( )
Returns
int

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

References $size.

◆ insert()

ilChatroomAuthInputGUI::insert ( ilTemplate  $a_tpl)

{}

Definition at line 128 of file class.ilChatroomAuthInputGUI.php.

129 {
130 $a_tpl->setCurrentBlock('prop_generic');
131 $a_tpl->setVariable('PROP_GENERIC', $this->render());
132 $a_tpl->parseCurrentBlock();
133 }
setVariable($variable, $value='')
Sets a variable value.
Definition: IT.php:613
parseCurrentBlock($part="DEFAULT")
Überladene Funktion, die auf den aktuelle Block vorher noch ein replace ausführt @access public.
setCurrentBlock($part="DEFAULT")
Überladene Funktion, die sich hier lokal noch den aktuellen Block merkt.

References ilTemplate\parseCurrentBlock(), ilTemplate\setCurrentBlock(), and HTML_Template_IT\setVariable().

+ Here is the call graph for this function:

◆ setCtrlPath()

ilChatroomAuthInputGUI::setCtrlPath (   $ctrl_path)
Parameters
array$ctrl_path

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

81 {
82 $this->ctrl_path = $ctrl_path;
83 }

◆ setSize()

ilChatroomAuthInputGUI::setSize (   $size)
Parameters
int$size

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

185 {
186 $this->size = $size;
187 }
font size
Definition: langcheck.php:162

References $size, and size.

◆ setValueByArray()

ilChatroomAuthInputGUI::setValueByArray ( array  $a_values)
Parameters
array$a_values

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

89 {
90 $this->values = array(
91 self::NAME_AUTH_PROP_1 => $a_values[$this->getPostVar()][self::NAME_AUTH_PROP_1],
92 self::NAME_AUTH_PROP_2 => $a_values[$this->getPostVar()][self::NAME_AUTH_PROP_2]
93 );
94
95 foreach($this->getSubItems() as $item)
96 {
97 $item->setValueByArray($a_values);
98 }
99 }
getPostVar()
Get Post Variable.

◆ uuidV4()

ilChatroomAuthInputGUI::uuidV4 ( )
private

Generates a pseudo random string following the RFC 4122.

Returns
string

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

51 {
52 return sprintf('%04x%04x-%04x-%04x-%04x-%04x%04x%04x',
53 // 32 bits for "time_low"
54 mt_rand(0, 0xffff), mt_rand(0, 0xffff),
55 // 16 bits for "time_mid"
56 mt_rand(0, 0xffff),
57 // 16 bits for "time_high_and_version",
58 // four most significant bits holds version number 4
59 mt_rand(0, 0x0fff) | 0x4000,
60 // 16 bits, 8 bits for "clk_seq_hi_res",
61 // 8 bits for "clk_seq_low",
62 // two most significant bits holds zero and one for variant DCE1.1
63 mt_rand(0, 0x3fff) | 0x8000,
64 // 48 bits for "node"
65 mt_rand(0, 0xffff), mt_rand(0, 0xffff), mt_rand(0, 0xffff)
66 );
67 }
sprintf('%.4f', $callTime)

References sprintf.

Field Documentation

◆ $ctrl_path

ilChatroomAuthInputGUI::$ctrl_path = array()
protected

Definition at line 18 of file class.ilChatroomAuthInputGUI.php.

◆ $size

ilChatroomAuthInputGUI::$size = 10
protected

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

◆ $values

ilChatroomAuthInputGUI::$values
protected
Initial value:
= array(
self::NAME_AUTH_PROP_1 => '',
self::NAME_AUTH_PROP_2 => ''
)

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

◆ NAME_AUTH_PROP_1

const ilChatroomAuthInputGUI::NAME_AUTH_PROP_1 = 'key'

Definition at line 12 of file class.ilChatroomAuthInputGUI.php.

◆ NAME_AUTH_PROP_2

const ilChatroomAuthInputGUI::NAME_AUTH_PROP_2 = 'secret'

Definition at line 13 of file class.ilChatroomAuthInputGUI.php.


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