| 1 | <?php |
||
| 6 | class ResourceAdapter implements TransformResource |
||
| 7 | { |
||
| 8 | /** @var mixed */ |
||
| 9 | protected $item; |
||
| 10 | |||
| 11 | /** @var callable */ |
||
| 12 | protected $rule; |
||
| 13 | |||
| 14 | /** @var callable */ |
||
| 15 | protected $includeRule; |
||
| 16 | |||
| 17 | 2 | public function __construct($item, callable $rule, callable $includeRule = null) |
|
| 23 | |||
| 24 | /** |
||
| 25 | * {@inheritdoc} |
||
| 26 | */ |
||
| 27 | 2 | public function transform() |
|
| 31 | |||
| 32 | /** |
||
| 33 | * {@inheritdoc} |
||
| 34 | */ |
||
| 35 | 1 | public function includeAttribute(string $name) |
|
| 42 | } |
||
| 43 |