| Conditions | 4 |
| Paths | 4 |
| Total Lines | 15 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 9 |
| CRAP Score | 4.25 |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | 4 | public function __construct($url, $namespaces = null) |
|
| 21 | { |
||
| 22 | 4 | $this->connection = new Connection($url); |
|
| 23 | |||
| 24 | 4 | if (is_array($namespaces)) { |
|
| 25 | 3 | foreach ($namespaces as $key => $value) { |
|
| 26 | 3 | $this->connection->ns($key, $value); |
|
| 27 | 3 | } |
|
| 28 | 3 | } |
|
| 29 | |||
| 30 | 4 | if (function_exists('dba_open')) { |
|
| 31 | $cache = sys_get_temp_dir() . "/caps.db"; |
||
| 32 | $this->connection->capabilityCache($cache); |
||
| 33 | } |
||
| 34 | 4 | } |
|
| 35 | |||
| 62 |