31 include_once
'class.ilMDBase.php';
36 function ilMDLanguage($a_rbac_id = 0,$a_obj_id = 0,$a_obj_type =
'')
46 if(is_object($lng_obj))
48 $this->language =& $lng_obj;
53 return is_object($this->language) ? $this->language :
false;
57 return is_object($this->language) ? $this->language->getLanguageCode() :
false;
62 if($this->db->autoExecute(
'il_meta_language',
66 $this->
setMetaId($this->db->getLastInsertId());
79 if($this->db->autoExecute(
'il_meta_language',
82 "meta_language_id = ".$ilDB->quote($this->
getMetaId())))
96 $query =
"DELETE FROM il_meta_language ".
97 "WHERE meta_language_id = ".$ilDB->quote($this->
getMetaId());
109 return array(
'rbac_id' => $this->
getRBACId(),
121 include_once
'Services/Migration/DBUpdate_426/classes/class.ilMDLanguageItem.php';
125 $query =
"SELECT * FROM il_meta_language ".
126 "WHERE meta_language_id = ".$ilDB->quote($this->
getMetaId());
154 function _getIds($a_rbac_id,$a_obj_id,$a_parent_id,$a_parent_type)
158 $query =
"SELECT meta_language_id FROM il_meta_language ".
159 "WHERE rbac_id = ".$ilDB->quote($a_rbac_id).
" ".
160 "AND obj_id = ".$ilDB->quote($a_obj_id).
" ".
161 "AND parent_id = ".$ilDB->quote($a_parent_id).
" ".
162 "AND parent_type = ".$ilDB->quote($a_parent_type);
167 $ids[] =
$row->meta_language_id;
169 return $ids ? $ids : array();