ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
ilTermsOfServiceDocumentCriterionAssignment Class Reference

Class ilTermsOfServiceDocumentCriterionAssignment. More...

+ Inheritance diagram for ilTermsOfServiceDocumentCriterionAssignment:
+ Collaboration diagram for ilTermsOfServiceDocumentCriterionAssignment:

Public Member Functions

 create ()
 
 update ()
 
 setCriterionValue (ilTermsOfServiceCriterionConfig $config)
 
 getCriterionValue ()
 
 getCriterionId ()
 
 equals ($other)
 
- Public Member Functions inherited from ActiveRecord
 getArConnector ()
 
 getArFieldList ()
 
 getConnectorContainerName ()
 Return the Name of your Connector Table More...
 
 setConnectorContainerName (string $connector_container_name)
 
 getPrimaryFieldValue ()
 
 setPrimaryFieldValue ($value)
 
 __construct ($primary_key=0)
 
 storeObjectToCache ()
 
 asStdClass ()
 
 buildFromArray (array $array)
 
 fixDateField ($field_name, $value)
 
 sleep ($field_name)
 
 wakeUp ($field_name, $field_value)
 
 getArrayForConnector ()
 
 installConnector ()
 
 store ()
 
 save ()
 
 create ()
 
 copy (int $new_id=0)
 
 afterObjectLoad ()
 
 read ()
 
 update ()
 
 delete ()
 
 __call ($name, $arguments)
 

Static Public Member Functions

static returnDbTableName ()
 
- Static Public Member Functions inherited from ActiveRecord
static returnDbTableName ()
 
static installDB ()
 
static renameDBField (string $old_name, string $new_name)
 
static tableExists ()
 
static fieldExists (string $field_name)
 
static removeDBField (string $field_name)
 
static updateDB ()
 
static resetDB ()
 
static truncateDB ()
 
static flushDB ()
 never use in ILIAS Core, Plugins only More...
 
static preloadObjects ()
 
static additionalParams (array $additional_params)
 
static findOrFail ($primary_key, array $add_constructor_args=array())
 Tries to find the object and throws an Exception if object is not found, instead of returning null. More...
 
static findOrGetInstance ($primary_key, array $add_constructor_args=array())
 
static where ($where, $operator=null)
 
static innerjoinAR (ActiveRecord $ar, $on_this, $on_external, array $fields=array(' *'), string $operator='=', $both_external=false)
 
static innerjoin ( $tablename, $on_this, $on_external, array $fields=array(' *'), string $operator='=', bool $both_external=false)
 
static leftjoin ( $tablename, $on_this, $on_external, array $fields=array(' *'), string $operator='=', bool $both_external=false)
 
static orderBy ($orderBy, string $orderDirection='ASC')
 
static dateFormat (string $date_format='d.m.Y - H:i:s')
 
static limit ($start, $end)
 
static affectedRows ()
 
static count ()
 
static get ()
 
static debug ()
 
static first ()
 
static getCollection ()
 
static last ()
 
static getFirstFromLastQuery ()
 
static connector (arConnector $connector)
 
static raw (bool $set_raw=true)
 
static getArray (?string $key=null, $values=null)
 
static _toCamelCase (string $str, bool $capitalise_first_char=false)
 

Protected Attributes

int $id = null
 
int $assigned_ts = 0
 
int $modification_ts = 0
 
int $doc_id = 0
 
string $criterion_id = ''
 
string $criterion_value
 
int $owner_usr_id = 0
 
int $last_modified_usr_id = 0
 
- Protected Attributes inherited from ActiveRecord
bool $ar_safe_read = true
 
string $connector_container_name = ''
 
bool $is_new = true
 

Private Attributes

const TABLE_NAME = 'tos_criterion_to_doc'
 

Additional Inherited Members

- Protected Member Functions inherited from ActiveRecord
 installDatabase ()
 
- Static Protected Member Functions inherited from ActiveRecord
static getCalledClass ()
 Returns an instance of the instatiated calling active record (needs to be done in static methods) : This should be cached somehow More...
 
static fromCamelCase (string $str)
 

Detailed Description

Member Function Documentation

◆ create()

ilTermsOfServiceDocumentCriterionAssignment::create ( )

Definition at line 101 of file class.ilTermsOfServiceDocumentCriterionAssignment.php.

101  : void
102  {
103  $this->setAssignedTs(time());
104 
105  parent::create();
106  }

◆ equals()

ilTermsOfServiceDocumentCriterionAssignment::equals (   $other)

Implements ilTermsOfServiceEquatable.

Definition at line 133 of file class.ilTermsOfServiceDocumentCriterionAssignment.php.

References getCriterionId(), and getCriterionValue().

Referenced by ilTermsOfServiceDocument\detachCriterion(), and ilTermsOfServiceDocumentCriterionAssignmentConstraint\filterEqualValues().

133  : bool
134  {
135  if (!($other instanceof static)) {
136  return false;
137  }
138 
139  $criterionIdCurrent = $this->getCriterionId();
140  $criterionIdNew = $other->getCriterionId();
141 
142  $valueCurrent = $this->getCriterionValue();
143  $valueNew = $other->getCriterionValue();
144 
145  $equals = (
146  $criterionIdCurrent === $criterionIdNew &&
147  $valueCurrent == $valueNew
148  );
149 
150  return $equals;
151  }
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getCriterionId()

◆ getCriterionValue()

◆ returnDbTableName()

static ilTermsOfServiceDocumentCriterionAssignment::returnDbTableName ( )
static

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

96  : string
97  {
98  return self::TABLE_NAME;
99  }

◆ setCriterionValue()

ilTermsOfServiceDocumentCriterionAssignment::setCriterionValue ( ilTermsOfServiceCriterionConfig  $config)

Definition at line 115 of file class.ilTermsOfServiceDocumentCriterionAssignment.php.

References ilTermsOfServiceCriterionConfig\toJson().

115  : void
116  {
117  $this->criterion_value = $config->toJson();
118  }
+ Here is the call graph for this function:

◆ update()

ilTermsOfServiceDocumentCriterionAssignment::update ( )

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

108  : void
109  {
110  $this->setModificationTs(time());
111 
112  parent::update();
113  }

Field Documentation

◆ $assigned_ts

int ilTermsOfServiceDocumentCriterionAssignment::$assigned_ts = 0
protected

◆ $criterion_id

string ilTermsOfServiceDocumentCriterionAssignment::$criterion_id = ''
protected

◆ $criterion_value

string ilTermsOfServiceDocumentCriterionAssignment::$criterion_value
protected

◆ $doc_id

int ilTermsOfServiceDocumentCriterionAssignment::$doc_id = 0
protected

◆ $id

int ilTermsOfServiceDocumentCriterionAssignment::$id = null
protected

◆ $last_modified_usr_id

int ilTermsOfServiceDocumentCriterionAssignment::$last_modified_usr_id = 0
protected

◆ $modification_ts

int ilTermsOfServiceDocumentCriterionAssignment::$modification_ts = 0
protected

◆ $owner_usr_id

int ilTermsOfServiceDocumentCriterionAssignment::$owner_usr_id = 0
protected

◆ TABLE_NAME

const ilTermsOfServiceDocumentCriterionAssignment::TABLE_NAME = 'tos_criterion_to_doc'
private

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