Skip to content

Commit e68b405

Browse files
author
Marko Dobric
committed
Add exception aware processor interface
1 parent e04c372 commit e68b405

File tree

2 files changed

+63
-0
lines changed

2 files changed

+63
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<?php
2+
3+
/*
4+
* This file is part of the Active Collab Authentication project.
5+
*
6+
* (c) A51 doo <[email protected]>. All rights reserved.
7+
*/
8+
9+
namespace ActiveCollab\Authentication\Authorizer\ExceptionProcessor;
10+
11+
use ActiveCollab\Authentication\Authorizer\ExceptionAware\ExceptionAwareInterface;
12+
13+
/**
14+
* @package ActiveCollab\Authentication\Authorizer\ExceptionProcessor
15+
*/
16+
trait ExceptionAwareProcessor
17+
{
18+
/**
19+
* @var ExceptionAwareInterface
20+
*/
21+
private $exception_processor;
22+
23+
/**
24+
* {@inheritdoc}
25+
*/
26+
public function getExceptionProcessor()
27+
{
28+
return $this->exception_processor;
29+
}
30+
31+
/**
32+
* @param ExceptionAwareInterface|null $exception_processor
33+
* @return $this
34+
*/
35+
protected function &setExceptionProcessor(ExceptionAwareInterface $exception_processor = null)
36+
{
37+
$this->exception_processor = $exception_processor;
38+
39+
return $this;
40+
}
41+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<?php
2+
3+
/*
4+
* This file is part of the Active Collab Authentication project.
5+
*
6+
* (c) A51 doo <[email protected]>. All rights reserved.
7+
*/
8+
9+
namespace ActiveCollab\Authentication\Authorizer\ExceptionProcessor;
10+
11+
use ActiveCollab\Authentication\Authorizer\ExceptionAware\ExceptionAwareInterface;
12+
13+
/**
14+
* @package ActiveCollab\Authentication\Authorizer\ExceptionProcessor
15+
*/
16+
interface ExceptionAwareProcessorInterface
17+
{
18+
/**
19+
* @return ExceptionAwareInterface
20+
*/
21+
public function getExceptionProcessor();
22+
}

0 commit comments

Comments
 (0)