1 | <?php |
||
8 | class FlareServiceProvider extends ServiceProvider |
||
9 | { |
||
10 | /** |
||
11 | * Array of Flare Service Providers to be Registered. |
||
12 | * |
||
13 | * @var array |
||
14 | */ |
||
15 | protected $serviceProviders = [ |
||
16 | \LaravelFlare\Flare\Providers\AuthServiceProvider::class, |
||
17 | \LaravelFlare\Flare\Providers\ArtisanServiceProvider::class, |
||
18 | \LaravelFlare\Flare\Providers\EventServiceProvider::class, |
||
19 | \LaravelFlare\Flare\Providers\RouteServiceProvider::class, |
||
20 | |||
21 | // External Components |
||
22 | \LaravelFlare\Fields\FieldServiceProvider::class, |
||
23 | ]; |
||
24 | |||
25 | /** |
||
26 | * Array of Flare assets and where they should be published to. |
||
27 | * |
||
28 | * @var array |
||
29 | */ |
||
30 | protected $assets = [ |
||
31 | 'public/flare' => 'vendor/flare', |
||
32 | 'public/AdminLTE/dist' => 'vendor/flare', |
||
33 | 'public/AdminLTE/plugins' => 'vendor/flare/plugins', |
||
34 | 'public/AdminLTE/bootstrap' => 'vendor/flare/bootstrap', |
||
35 | ]; |
||
36 | |||
37 | /** |
||
38 | * Create a new service provider instance. |
||
39 | * |
||
40 | * @param \Illuminate\Contracts\Foundation\Application $app |
||
41 | * @return void |
||
|
|||
42 | */ |
||
43 | public function __construct($app) |
||
51 | |||
52 | /** |
||
53 | * Perform post-registration booting of services. |
||
54 | */ |
||
55 | public function boot() |
||
67 | |||
68 | /** |
||
69 | * Register any package services. |
||
70 | */ |
||
71 | public function register() |
||
76 | |||
77 | /** |
||
78 | * Register Service Providers. |
||
79 | */ |
||
80 | protected function registerServiceProviders() |
||
86 | |||
87 | /** |
||
88 | * Register the Flare Facade. |
||
89 | */ |
||
90 | protected function registerFlareFacade() |
||
94 | |||
95 | /** |
||
96 | * Publishes the Flare Assets to the appropriate directories. |
||
97 | */ |
||
98 | protected function publishAssets() |
||
108 | |||
109 | /** |
||
110 | * Publishes the Flare Config File. |
||
111 | */ |
||
112 | protected function publishConfig() |
||
118 | |||
119 | /** |
||
120 | * Publishes the Flare Database Migrations. |
||
121 | */ |
||
122 | protected function publishMigrations() |
||
128 | |||
129 | /** |
||
130 | * Publishes the Flare Views and defines the location |
||
131 | * they should be looked for in the application. |
||
132 | */ |
||
133 | protected function publishViews() |
||
140 | |||
141 | /** |
||
142 | * Returns the path to a provided file within the Flare package. |
||
143 | * |
||
144 | * @param bool $fiepath |
||
145 | * |
||
146 | * @return string |
||
147 | */ |
||
148 | private function basePath($filepath = false) |
||
152 | } |
||
153 |
Adding a
@return
annotation to a constructor is not recommended, since a constructor does not have a meaningful return value.Please refer to the PHP core documentation on constructors.