I have following class.
    class User 
    {
        private $userRoles = array();
        //Populate the user object when it's created
        public function __construct($dbConn,$user_id)
        {
                self::loadRoles($dbConn,$user_id);//Initiate the userroles
        }
        //Fill the array with this user's roles, it's
        protected static function loadRoles($dbConn,$user_id)
        {
            $fetchRoles = $dbConn->prepare("SELECT tbl_user_role.role_id, tbl_roles.role_name FROM tbl_user_role JOIN tbl_roles ON tbl_user_role.role_id = tbl_roles.id WHERE tbl_user_role.user_id = :user_id");
            $fetchRoles->bindParam(':user_id', $user_id);
            $fetchRoles->execute();
                    //Populate the array
            while($row = $fetchRoles->fetch(PDO::FETCH_ASSOC))
            {
                $this->userRoles[$row["role_name"]] = Role::getRole($dbConn,$row["role_id"]); 
(Fatal error: Using $this when not in object context.)
            }
        } 
    }
Getting above error on this function protected static function loadRoles($dbConn,$user_id). I am working with role based access control. 
Please help me on this.
 
     
    