1 | <?php |
||
15 | abstract class AbacLoader extends FileLoader { |
||
16 | /** |
||
17 | * Must be overrided to contains an array of allowed extension |
||
18 | */ |
||
19 | protected static $_EXTENSION_ALLOWED_A = []; |
||
20 | |||
21 | /** @var ConfigurationManager The configuration manage instanciator and user of this AbacLoader Instance */ |
||
22 | protected $configurationManger; |
||
23 | |||
24 | 18 | public function __construct( FileLocatorInterface $locator ) { |
|
27 | |||
28 | /** |
||
29 | * Method to load a resource and return an array that contains decoded data of the resource |
||
30 | * |
||
31 | * @param string $resource The path of the resource to load |
||
32 | * @param null $type ?? |
||
33 | * |
||
34 | * @return string |
||
35 | */ |
||
36 | abstract public function load( $resource, $type = null ); |
||
37 | |||
38 | // /** |
||
39 | // * Method to check if a resource ( by his path ) is supported by the loader |
||
40 | // * |
||
41 | // * @param string $resource The path of the resource to check |
||
42 | // * @param null $type ?? |
||
43 | // * |
||
44 | // * @return boolean Return true if the resource is supported by the loader |
||
45 | // */ |
||
46 | // abstract public function supports( $resource, $type = null ); |
||
47 | |||
48 | /** |
||
49 | * Method to check if a resource is supported by the loader |
||
50 | * This method check only extension file |
||
51 | * |
||
52 | * @param $resource |
||
53 | * |
||
54 | * @return boolean Return true if the extension of the ressource is supported by the loader |
||
55 | */ |
||
56 | 18 | public static final function supportsExtension( $resource ) { |
|
59 | |||
60 | /** |
||
61 | * Method to return allowed extension for file to load with the loader |
||
62 | * @return mixed |
||
63 | */ |
||
64 | 18 | private static final function getExtensionAllowed() { |
|
67 | } |
||
68 | |||
70 |