Collections
1 month ago
Concerns
3 weeks ago
Console
1 week ago
Constants
1 month ago
Contracts
1 week ago
Database
1 week ago
Discovery
1 month ago
Exceptions
1 week ago
Filesystem
1 week ago
Http
1 week ago
Managers
1 week ago
Middlewares
1 month ago
Polyfill
1 month ago
Routing
1 week ago
Supports
1 week ago
Validation
1 week ago
View
1 week ago
Wordpress
1 week ago
ApiExceptionHandler.php
1 month ago
Application.php
1 week ago
Container.php
1 month ago
CoreServiceProvider.php
1 week ago
DTO.php
1 month ago
Facade.php
1 month ago
Listener.php
3 weeks ago
Resource.php
1 week ago
Route.php
1 week ago
Sanitizer.php
1 week ago
ServiceProvider.php
1 month ago
SiteExceptionHandler.php
1 week ago
helpers.php
1 week ago
ServiceProvider.php
57 lines
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * Abstract base for application service providers with register and boot lifecycle hooks. |
| 5 | * Receives the Application instance and binds services in register while wiring hooks in boot. |
| 6 | * Pattern for modular plugin feature registration. |
| 7 | * |
| 8 | * @package Framework |
| 9 | * @since 1.0.0 |
| 10 | */ |
| 11 | namespace Kirki\Framework; |
| 12 | |
| 13 | \defined('ABSPATH') || exit; |
| 14 | abstract class ServiceProvider |
| 15 | { |
| 16 | /** |
| 17 | * The app. |
| 18 | * |
| 19 | * @var Application |
| 20 | * |
| 21 | * @since 1.0.0 |
| 22 | */ |
| 23 | protected $app; |
| 24 | /** |
| 25 | * Create a new service provider constructor |
| 26 | * |
| 27 | * @param Application $app The app. |
| 28 | * |
| 29 | * @return void |
| 30 | * |
| 31 | * @since 1.0.0 |
| 32 | */ |
| 33 | public function __construct(Application $app) |
| 34 | { |
| 35 | $this->app = $app; |
| 36 | } |
| 37 | /** |
| 38 | * Register the service provider. |
| 39 | * |
| 40 | * @return void |
| 41 | * |
| 42 | * @since 1.0.0 |
| 43 | */ |
| 44 | public abstract function register(); |
| 45 | /** |
| 46 | * Boot the service provider. |
| 47 | * |
| 48 | * @return void |
| 49 | * |
| 50 | * @since 1.0.0 |
| 51 | */ |
| 52 | public function boot() |
| 53 | { |
| 54 | // |
| 55 | } |
| 56 | } |
| 57 |