| @@ 192-211 (lines=20) @@ | ||
| 189 | */ |
|
| 190 | public function library($library, $params = NULL, $object_name = NULL) |
|
| 191 | { |
|
| 192 | if (empty($library)) |
|
| 193 | { |
|
| 194 | return $this; |
|
| 195 | } |
|
| 196 | elseif (is_array($library)) |
|
| 197 | { |
|
| 198 | foreach ($library as $key => $value) |
|
| 199 | { |
|
| 200 | if (is_int($key)) |
|
| 201 | { |
|
| 202 | $this->library($value, $params); |
|
| 203 | } |
|
| 204 | else |
|
| 205 | { |
|
| 206 | $this->library($key, $params, $value); |
|
| 207 | } |
|
| 208 | } |
|
| 209 | ||
| 210 | return $this; |
|
| 211 | } |
|
| 212 | ||
| 213 | if ($params !== NULL && ! is_array($params)) |
|
| 214 | { |
|
| @@ 238-250 (lines=13) @@ | ||
| 235 | */ |
|
| 236 | public function model($model, $name = '', $db_conn = FALSE) |
|
| 237 | { |
|
| 238 | if (empty($model)) |
|
| 239 | { |
|
| 240 | return $this; |
|
| 241 | } |
|
| 242 | elseif (is_array($model)) |
|
| 243 | { |
|
| 244 | foreach ($model as $key => $value) |
|
| 245 | { |
|
| 246 | is_int($key) ? $this->model($value, '', $db_conn) : $this->model($key, $value, $db_conn); |
|
| 247 | } |
|
| 248 | ||
| 249 | return $this; |
|
| 250 | } |
|
| 251 | ||
| 252 | $path = ''; |
|
| 253 | ||