| 1 | <?php |
||
| 11 | abstract class AppServiceProvider extends AbstractServiceProvider implements BootableServiceProviderInterface |
||
| 12 | { |
||
| 13 | protected $provides = [ |
||
| 14 | Config::class, |
||
| 15 | 'environment', |
||
| 16 | 'base_path', |
||
| 17 | 'resources_path', |
||
| 18 | ]; |
||
| 19 | |||
| 20 | /** |
||
| 21 | * Determine environment where application is currently is running on. |
||
| 22 | * |
||
| 23 | * @return string |
||
| 24 | */ |
||
| 25 | abstract public function environment(): string; |
||
| 26 | |||
| 27 | /** |
||
| 28 | * Base path of the application. |
||
| 29 | * |
||
| 30 | * @return string |
||
| 31 | */ |
||
| 32 | abstract public function basePath(): string; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * Path to the "resources folder". |
||
| 36 | * |
||
| 37 | * @return string |
||
| 38 | */ |
||
| 39 | abstract public function resourcesPath(): string; |
||
| 40 | |||
| 41 | /** |
||
| 42 | * Method will be invoked on registration of a service provider implementing |
||
| 43 | * this interface. Provides ability for eager loading of Service Providers. |
||
| 44 | * |
||
| 45 | * @return void |
||
| 46 | */ |
||
| 47 | 1 | public function boot(): void |
|
| 56 | |||
| 57 | /** |
||
| 58 | * Use the register method to register items with the container via the |
||
| 59 | * protected $this->container property or the `getContainer` method |
||
| 60 | * from the ContainerAwareTrait. |
||
| 61 | * |
||
| 62 | * @return void |
||
| 63 | */ |
||
| 64 | 1 | public function register(): void |
|
| 70 | } |
||
| 71 |