| Total Complexity | 3 |
| Total Lines | 34 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 24 | class Expose extends AbstractAnnotation |
||
| 25 | { |
||
| 26 | /** |
||
| 27 | * Expose this property during serialization |
||
| 28 | * |
||
| 29 | * @var bool |
||
| 30 | */ |
||
| 31 | private $serialize = true; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * Expose this property during deserialization |
||
| 35 | * |
||
| 36 | * @var bool |
||
| 37 | */ |
||
| 38 | private $deserialize = true; |
||
| 39 | |||
| 40 | /** |
||
| 41 | * Initialize annotation data |
||
| 42 | */ |
||
| 43 | 3 | protected function init(): void |
|
| 47 | 3 | } |
|
| 48 | |||
| 49 | /** |
||
| 50 | * Returns true if the property should be exposed based on the direction (serialize/deserialize) |
||
| 51 | * |
||
| 52 | * @param bool $serialize |
||
| 53 | * @return bool |
||
| 54 | */ |
||
| 55 | 3 | public function shouldExpose(bool $serialize): bool |
|
| 60 |