Completed
Push — master ( 7eaa21...d5f163 )
by Iacovos
8s
created

CallableResolver   A

Complexity

Total Complexity 3

Size/Duplication

Total Lines 28
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 100%

Importance

Changes 2
Bugs 0 Features 2
Metric Value
wmc 3
c 2
b 0
f 2
lcom 0
cbo 2
dl 0
loc 28
ccs 5
cts 5
cp 1
rs 10

3 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A resolve() 0 3 1
A resolveSafe() 0 3 1
1
<?php
2
3
namespace Softius\ResourcesResolver;
4
5
/**
6
 * Class CallableResolver
7
 * @package Softius\ResourcesResolver
8
 */
9
class CallableResolver implements StrategyAwareInterface
10
{
11
	use StrategyAwareTrait;
12
13
	/**
14
	 * CallableResolver constructor.
15
     */
16 3
	public function __construct()
17
	{
18 3
		$this->setStrategy(new DefaultCallableStrategy());
19 3
	}
20
21
	/**
22
	 * @param string $in
23
	 * @return mixed
24
     */
25 3
	public function resolve($in) {
26 3
        return $this->getStrategy()->resolve($in);
27
	}
28
29
	/**
30
	 * @param string $in
31
	 * @return mixed
32
	 */
33
	public function resolveSafe($in) {
34
		return $this->getStrategy()->resolveSafe($in);
35
	}
36
}