Taufan Aditya | ac5373a | 2012-03-28 16:03:38 +0700 | [diff] [blame] | 1 | <?php |
2 | |||||
Taufan Aditya | d44d720 | 2012-03-28 16:24:23 +0700 | [diff] [blame] | 3 | class Mock_Libraries_Table extends CI_Table { |
4 | |||||
5 | // Overide inaccesible private or protected method | ||||
6 | public function __call($method, $params) | ||||
7 | { | ||||
8 | if (is_callable(array($this, '_'.$method))) | ||||
9 | { | ||||
10 | return call_user_func_array(array($this, '_'.$method), $params); | ||||
11 | } | ||||
12 | |||||
13 | throw new BadMethodCallException('Method '.$method.' was not found'); | ||||
14 | } | ||||
15 | } |