| Total Complexity | 2 |
| Total Lines | 24 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 14 | final class FastlyCachePurger implements PurgerInterface |
||
| 15 | { |
||
| 16 | /** |
||
| 17 | * @SuppressWarnings("PHPMD.BooleanArgumentFlag") |
||
| 18 | * @Named("fastlyServiceId=fastlyServiceId,enableSoftPurge=fastlyEnableSofrPurge") |
||
| 19 | */ |
||
| 20 | public function __construct( |
||
| 21 | private PurgeApi $purgeApi, |
||
| 22 | #[Named('fastlyServiceId')] private string $fastlyServiceId, |
||
| 23 | #[Named('fastlyEnableSoftPurge')] private bool $enableSoftPurge, |
||
| 24 | ) { |
||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * @throws ApiException |
||
| 29 | * |
||
| 30 | * @see https://developer.fastly.com/reference/api/purging/ |
||
| 31 | */ |
||
| 32 | public function __invoke(string $tag): void |
||
| 38 | ]); |
||
| 39 | } |
||
| 41 |