ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
ilTermsOfServiceCriterionConfig Class Reference

Class ilTermsOfServiceCriterionConfig. More...

+ Inheritance diagram for ilTermsOfServiceCriterionConfig:
+ Collaboration diagram for ilTermsOfServiceCriterionConfig:

Public Member Functions

 __construct ($data=[])
 ilTermsOfServiceCriterionConfig constructor. More...
 
 toJson ()
 
 fromJson (string $json)
 
Parameters
string$json
More...
 
 jsonSerialize ()
 
 toJson ()
 
 fromJson (string $json)
 

Detailed Description

Constructor & Destructor Documentation

◆ __construct()

ilTermsOfServiceCriterionConfig::__construct (   $data = [])

ilTermsOfServiceCriterionConfig constructor.

Parameters
string|array

Definition at line 14 of file class.ilTermsOfServiceCriterionConfig.php.

15 {
16 if (is_array($data)) {
17 parent::__construct($data);
18 } else {
19 parent::__construct([]);
20
21 if (is_string($data)) {
22 $this->fromJson($data);
23 }
24 }
25 }
$data
Definition: bench.php:6

References $data, and fromJson().

+ Here is the call graph for this function:

Member Function Documentation

◆ fromJson()

ilTermsOfServiceCriterionConfig::fromJson ( string  $json)

Parameters
string$json

Implements ilTermsOfServiceJsonDeserialization.

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

41 {
42 $data = json_decode($json, true);
43
44 $this->exchangeArray($data);
45 }

References $data.

Referenced by __construct().

+ Here is the caller graph for this function:

◆ jsonSerialize()

ilTermsOfServiceCriterionConfig::jsonSerialize ( )

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

51 {
52 return $this->getArrayCopy();
53 }

◆ toJson()

ilTermsOfServiceCriterionConfig::toJson ( )

Implements ilTermsOfServiceJsonSerialization.

Definition at line 30 of file class.ilTermsOfServiceCriterionConfig.php.

30 : string
31 {
32 $json = json_encode($this);
33
34 return $json;
35 }

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