1 | <?php |
||
9 | class Model |
||
10 | { |
||
11 | public $crudApi; |
||
12 | |||
13 | /** |
||
14 | * Model constructor. |
||
15 | * |
||
16 | * @param CrudApi $crudApi |
||
17 | */ |
||
18 | public function __construct(CrudApi $crudApi) |
||
22 | |||
23 | /** |
||
24 | * Get a model from the currently set namespace and model. |
||
25 | * |
||
26 | * If the model does not exist from the base namespace it will also |
||
27 | * look in the namespace\Models as a secondary convention. |
||
28 | * |
||
29 | * @return false|string |
||
30 | */ |
||
31 | public function getModel($model = null) |
||
79 | |||
80 | /** |
||
81 | * Return the crudapi model instance. |
||
82 | * @return mixed |
||
83 | */ |
||
84 | public function instance() |
||
94 | |||
95 | /** |
||
96 | * Retrieve any additional configured namespaces. |
||
97 | * @return mixed |
||
98 | */ |
||
99 | public function getAdditionalNamespaces() |
||
103 | } |
||
104 |