36        $this->db = 
$DIC->database();
 
   70        $this->context_obj_id = $a_context_obj_id;
 
   90        $this->context_obj_type = $a_context_obj_type;
 
  110        $this->context_sub_obj_id = $a_context_sub_obj_id;
 
  130        $this->context_sub_obj_type = $a_context_sub_obj_type;
 
  170        $this->title = $a_title;
 
  191        $this->
setId(
$ilDB->nextId(
"il_custom_block"));
 
  192        $query = 
"INSERT INTO il_custom_block (" .
 
  195            ", context_obj_type" .
 
  196            ", context_sub_obj_id" .
 
  197            ", context_sub_obj_type" .
 
  219        $query = 
"SELECT * FROM il_custom_block WHERE id = " .
 
  222        $rec = 
$ilDB->fetchAssoc($set);
 
  240        $query = 
"UPDATE il_custom_block SET " .
 
  247            " WHERE id = " . 
$ilDB->quote($this->
getId(), 
"integer");
 
  256    public function delete()
 
  260        $query = 
"DELETE FROM il_custom_block" .
 
  261            " WHERE id = " . 
$ilDB->quote($this->
getId(), 
"integer");
 
  274        $query = 
"SELECT id, context_obj_id, context_obj_type, context_sub_obj_id, context_sub_obj_type, type, title " .
 
  275            "FROM il_custom_block " .
 
  285        while ($rec = 
$ilDB->fetchAssoc($set)) {
 
  300        $query = 
"SELECT id, context_obj_id, context_obj_type, context_sub_obj_id, context_sub_obj_type, type, title " .
 
  301            "FROM il_custom_block " .
 
  305        if ($a_include_sub_obj_id) {
 
  313        while ($rec = 
$ilDB->fetchAssoc($set)) {
 
  327        die(
"ilCustomBlock::queryTitleForId is deprecated");
 
  352        $query = 
"SELECT count(*) as cnt " .
 
  353            "FROM il_custom_block " .
 
  359                " AND type = " . 
$ilDB->quote($this->
getType(), 
"text") . 
"";
 
  363        while ($rec = 
$ilDB->fetchAssoc($set)) {
 
  376        $query = 
"SELECT id, context_obj_id, context_obj_type, context_sub_obj_id, context_sub_obj_type, type, title " .
 
  377            "FROM il_custom_block " .
 
  379                $ilDB->in(
"context_obj_id", $a_context_obj_ids, 
"", 
"integer") .
 
  380                " AND context_obj_type = " . 
$ilDB->quote($a_context_obj_type, 
"text") .
 
  384        while ($rec = 
$ilDB->fetchAssoc($set)) {
 
An exception for terminatinating execution or to throw for unit testing.
This is the super class of all custom blocks.
queryCntBlockForContext()
Query CntBlockForContext.
setTitle($a_title)
Set Title.
queryTitleForId()
Query TitleForId.
getContextObjType()
Get ContextObjType.
setContextSubObjType($a_context_sub_obj_type)
Set ContextSubObjType.
querygetBlocksForContext()
Query getBlocksForContext.
queryBlocksForContext($a_include_sub_obj=true)
Query BlocksForContext.
update()
Update item in database.
static multiBlockQuery($a_context_obj_type, array $a_context_obj_ids)
setContextObjType($a_context_obj_type)
Set ContextObjType.
setContextObjId($a_context_obj_id)
Set ContextObjId.
getContextSubObjType()
Get ContextSubObjType.
__construct($a_id=0)
Constructor.
getContextObjId()
Get ContextObjId.
setType($a_type)
Set Type.
read()
Read item from database.
getContextSubObjId()
Get ContextSubObjId.
setContextSubObjId($a_context_sub_obj_id)
Set ContextSubObjId.