1 | <?php |
||
17 | class NonceService implements NonceServiceInterface |
||
18 | { |
||
19 | /** |
||
20 | * @var NonceMapperInterface |
||
21 | */ |
||
22 | protected $nonceMapper; |
||
23 | |||
24 | /** |
||
25 | * @var ModuleOptions |
||
26 | */ |
||
27 | protected $moduleOptions; |
||
28 | |||
29 | /** |
||
30 | * @param NonceMapperInterface $nonceMapper |
||
31 | * @param ModuleOptions $moduleOptions |
||
32 | */ |
||
33 | 12 | public function __construct(NonceMapperInterface $nonceMapper, ModuleOptions $moduleOptions) |
|
38 | |||
39 | /** |
||
40 | * {@inheritdoc} |
||
41 | */ |
||
42 | 4 | public function createNonce(NonceOwnerInterface $owner, DateTime $expirationDate = null, $namespace = null) |
|
56 | |||
57 | /** |
||
58 | * {@inheritdoc} |
||
59 | * |
||
60 | * proxies to the data mapper |
||
61 | */ |
||
62 | 2 | public function findNonce($uuid, $namespace = null) |
|
66 | |||
67 | /** |
||
68 | * {@inheritdoc} |
||
69 | */ |
||
70 | 7 | public function isValid(Nonce $nonce) |
|
80 | |||
81 | /** |
||
82 | * {@inheritdoc} |
||
83 | */ |
||
84 | 4 | public function consumeNonce(Nonce $nonce) |
|
98 | } |
||
99 |