Public Member Functions | Data Fields

ilLinkCheckNotify Class Reference

Public Member Functions

 ilLinkCheckNotify (&$db)
 setUserId ($a_usr_id)
 getUserId ()
 setObjId ($a_obj_id)
 getObjId ()
 addNotifier ()
 deleteNotifier ()
 _getNotifyStatus ($a_usr_id, $a_obj_id)
 _deleteUser ($a_usr_id)
 _deleteObject ($a_obj_id)
 _getNotifiers ($a_obj_id)
 _getAllNotifiers (&$db)

Data Fields

 $db = null

Detailed Description

Definition at line 32 of file class.ilLinkCheckNotify.php.


Member Function Documentation

ilLinkCheckNotify::_deleteObject ( a_obj_id  ) 

Definition at line 109 of file class.ilLinkCheckNotify.php.

References $query.

Referenced by ilObjLinkResource::delete().

        {
                global $ilDB;

                $query = "DELETE FROM link_check_report ".
                        "WHERE obj_id = '".$a_obj_id."'";

                $ilDB->query($query);

                return true;
        }

Here is the caller graph for this function:

ilLinkCheckNotify::_deleteUser ( a_usr_id  ) 

Definition at line 97 of file class.ilLinkCheckNotify.php.

References $query.

Referenced by ilObjUser::delete().

        {
                global $ilDB;

                $query = "DELETE FROM link_check_report ".
                        "WHERE usr_id = '".$a_usr_id."'";

                $ilDB->query($query);

                return true;
        }

Here is the caller graph for this function:

ilLinkCheckNotify::_getAllNotifiers ( &$  db  ) 

Definition at line 137 of file class.ilLinkCheckNotify.php.

References $db, $query, $res, and $row.

Referenced by ilLinkChecker::__sendMail().

        {

                $query = "SELECT * FROM link_check_report ";

                $res = $db->query($query);
                while($row = $res->fetchRow(DB_FETCHMODE_OBJECT))
                {
                        $usr_ids[$row->usr_id][] = $row->obj_id;
                }

                return $usr_ids ? $usr_ids : array();
        }                       

Here is the caller graph for this function:

ilLinkCheckNotify::_getNotifiers ( a_obj_id  ) 

Definition at line 121 of file class.ilLinkCheckNotify.php.

References $query, $res, and $row.

        {
                global $ilDB;

                $query = "SELECT * FROM link_check_report ".
                        "WHERE obj_id = '".$a_obj_id."'";

                $res = $ilDB->query($query);
                while($row = $res->fetchRow(DB_FETCHMODE_OBJECT))
                {
                        $usr_ids[] = $row->usr_id;
                }

                return $usr_ids ? $usr_ids : array();
        }

ilLinkCheckNotify::_getNotifyStatus ( a_usr_id,
a_obj_id 
)

Definition at line 84 of file class.ilLinkCheckNotify.php.

References $query, and $res.

Referenced by ilObjContentObjectGUI::linkChecker(), and ilObjLinkResourceGUI::linkCheckerObject().

        {
                global $ilDB;

                $query = "SELECT * FROM link_check_report ".
                        "WHERE obj_id = '".$a_obj_id."' ".
                        "AND usr_id = '".$a_usr_id."'";

                $res = $ilDB->query($query);

                return $res->numRows() ? true : false;
        }

Here is the caller graph for this function:

ilLinkCheckNotify::addNotifier (  ) 

Definition at line 59 of file class.ilLinkCheckNotify.php.

References $query, and deleteNotifier().

        {
                $this->deleteNotifier();

                $query = "INSERT INTO link_check_report ".
                        "SET obj_id = '".$this->getObjId()."', ".
                        "usr_id = '".$this->getUserId()."'";

                $this->db->query($query);

                return true;
        }

Here is the call graph for this function:

ilLinkCheckNotify::deleteNotifier (  ) 

Definition at line 72 of file class.ilLinkCheckNotify.php.

References $query.

Referenced by addNotifier().

        {
                $query = "DELETE FROM link_check_report ".
                        "WHERE obj_id = '".$this->getObjId()."' ".
                        "AND usr_id = '".$this->getUserId()."'";

                $this->db->query($query);

                return true;
        }

Here is the caller graph for this function:

ilLinkCheckNotify::getObjId (  ) 

Definition at line 54 of file class.ilLinkCheckNotify.php.

        {
                return $this->obj_id;
        }

ilLinkCheckNotify::getUserId (  ) 

Definition at line 46 of file class.ilLinkCheckNotify.php.

        {
                return $this->usr_id;
        }

ilLinkCheckNotify::ilLinkCheckNotify ( &$  db  ) 

Definition at line 37 of file class.ilLinkCheckNotify.php.

References $db.

        {
                $this->db =& $db;
        }

ilLinkCheckNotify::setObjId ( a_obj_id  ) 

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

        {
                $this->obj_id = $a_obj_id;
        }

ilLinkCheckNotify::setUserId ( a_usr_id  ) 

Definition at line 42 of file class.ilLinkCheckNotify.php.

        {
                $this->usr_id = $a_usr_id;
        }


Field Documentation

ilLinkCheckNotify::$db = null

Definition at line 34 of file class.ilLinkCheckNotify.php.

Referenced by _getAllNotifiers(), and ilLinkCheckNotify().


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