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

Abstract internal link db bridge. More...

+ Inheritance diagram for ilADTInternalLinkDBBridge:
+ Collaboration diagram for ilADTInternalLinkDBBridge:

Public Member Functions

 readRecord (array $a_row)
 read record More...
 
 prepareInsert (array &$a_fields)
 prepare insert More...
 
- Public Member Functions inherited from ilADTDBBridge
 __construct (ilADT $a_adt)
 Constructor. More...
 
 getADT ()
 Get ADT. More...
 
 setTable ($a_table)
 Set table name. More...
 
 getTable ()
 Get table name. More...
 
 setElementId ($a_value)
 Set element id (aka DB column[s] [prefix]) More...
 
 getElementId ()
 Get element id. More...
 
 setPrimary (array $a_value)
 Set primary fields (in MDB2 format) More...
 
 getPrimary ()
 Get primary fields. More...
 
 buildPrimaryWhere ()
 Convert primary keys array to sql string. More...
 
 readRecord (array $a_row)
 Import DB values to ADT. More...
 
 prepareInsert (array &$a_fields)
 Prepare ADT values for insert. More...
 
 afterInsert ()
 After insert hook to enable sub-tables. More...
 
 prepareUpdate (array &$a_fields)
 Prepare ADT values for update. More...
 
 afterUpdate ()
 After update hook to enable sub-tables. More...
 
 afterDelete ()
 After delete hook to enable sub-tables. More...
 

Protected Member Functions

 isValidADT (ilADT $a_adt)
 check valid type More...
 
- Protected Member Functions inherited from ilADTDBBridge
 isValidADT (ilADT $a_adt)
 Check if given ADT is valid. More...
 
 setADT (ilADT $a_adt)
 Set ADT. More...
 

Additional Inherited Members

- Protected Attributes inherited from ilADTDBBridge
 $adt
 
 $table
 
 $id
 
 $primary = []
 

Detailed Description

Abstract internal link db bridge.

Author
Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om

Definition at line 11 of file class.ilADTInternalLinkDBBridge.php.

Member Function Documentation

◆ isValidADT()

ilADTInternalLinkDBBridge::isValidADT ( ilADT  $a_adt)
protected

check valid type

Parameters
ilADT$a_adt
Returns
bool

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

19  {
20  return $a_adt instanceof ilADTInternalLink;
21  }

◆ prepareInsert()

ilADTInternalLinkDBBridge::prepareInsert ( array $a_fields)

prepare insert

Parameters
array$a_fields

Definition at line 36 of file class.ilADTInternalLinkDBBridge.php.

References ilADTDBBridge\getADT(), and ilADTDBBridge\getElementId().

37  {
38  $a_fields[$this->getElementId()] = ["integer",$this->getADT()->getTargetRefId()];
39  }
getElementId()
Get element id.
+ Here is the call graph for this function:

◆ readRecord()

ilADTInternalLinkDBBridge::readRecord ( array  $a_row)

read record

Parameters
array$a_row

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

References ilADTDBBridge\getADT(), and ilADTDBBridge\getElementId().

28  {
29  $this->getADT()->setTargetRefId($a_row[$this->getElementId()]);
30  }
getElementId()
Get element id.
+ Here is the call graph for this function:

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