Lines
100.00%
7 / 7
Functions and Methods
100.00%
1 / 1
Classes and Traits
100.00%
1 / 1
| Name | Lines | Functions and Methods | CRAP | Classes and Traits | ||||||
|---|---|---|---|---|---|---|---|---|---|---|
| Apiclient | 100.00% | 7 / 7 | 100.00% | 1 / 1 | 1 | 100.00% | 1 / 1 | |||
| readEntity | 100.00% | 7 / 7 | 100.00% | 1 / 1 | 1 | |||||
| 1 | <?php | |
| 2 | ||
| 3 | namespace BO\Zmsbackend\Apikey\Service; | |
| 4 | ||
| 5 | use BO\Zmsentities\Apiclient as Entity; | |
| 6 | ||
| 7 | class Apiclient extends \BO\Zmsbackend\Base | |
| 8 | { | |
| 9 | public static $cache = []; | |
| 10 | ||
| 11 | public function readEntity($clientKey): Entity | |
| 12 | { | |
| 13 | $query = new \BO\Zmsbackend\Apikey\Repository\Apiclient(\BO\Zmsbackend\Query\Base::SELECT); | |
| 14 | $query | |
| 15 | ->addEntityMapping() | |
| 16 | ->addResolvedReferences(0) | |
| 17 | ->addConditionApiclientKey($clientKey); | |
| 18 | $entity = $this->fetchOne($query, new Entity()); | |
| 19 | return $entity; | |
| 20 | } | |
| 21 | } |