class LogServiceProvider extends ServiceProvider

Properties

protected Application $app

The application instance.

from  ServiceProvider
protected bool $defer

Indicates if loading of the provider is deferred.

from  ServiceProvider
static protected array $publishes

The paths that should be published.

from  ServiceProvider
static protected array $publishGroups

The paths that should be published by group.

from  ServiceProvider

Methods

void
__construct(Application $app)

Create a new service provider instance.

void
mergeConfigFrom(string $path, string $key)

Merge the given configuration with the existing configuration.

void
loadRoutesFrom(string $path)

Load the given routes file if routes are not already cached.

void
loadViewsFrom(string $path, string $namespace)

Register a view file namespace.

void
loadTranslationsFrom(string $path, string $namespace)

Register a translation file namespace.

void
loadMigrationsFrom(array|string $paths)

Register a database migration path.

void
publishes(array $paths, string $group = null)

Register paths to be published by the publish command.

void
ensurePublishArrayInitialized(string $class)

Ensure the publish array for the service provider is initialized.

void
addPublishGroup(string $group, array $paths)

Add a publish group / tag to the service provider.

static array
pathsToPublish(string $provider = null, string $group = null)

Get the paths to publish.

static array
pathsForProviderOrGroup(string|null $provider, string|null $group)

Get the paths for the provider or group (or both).

static array
pathsForProviderAndGroup(string $provider, string $group)

Get the paths for the provider and group.

void
commands(array|mixed $commands)

Register the package's custom Artisan commands.

array
provides()

Get the services provided by the provider.

array
when()

Get the events that trigger this service provider to register.

bool
isDeferred()

Determine if the provider is deferred.

static array
compiles() deprecated

Get a list of files that should be compiled for the package.

void
register()

Register the service provider.

createLogger()

Create the logger.

string
channel()

Get the name of the log "channel".

void
configureHandler(Writer $log)

Configure the Monolog handlers for the application.

void
configureSingleHandler(Writer $log)

Configure the Monolog handlers for the application.

void
configureDailyHandler(Writer $log)

Configure the Monolog handlers for the application.

void
configureSyslogHandler(Writer $log)

Configure the Monolog handlers for the application.

void
configureErrorlogHandler(Writer $log)

Configure the Monolog handlers for the application.

string
handler()

Get the default log handler.

string
logLevel()

Get the log level for the application.

int
maxFiles()

Get the maximum number of log files for the application.

Details

in ServiceProvider at line 43
void __construct(Application $app)

Create a new service provider instance.

Parameters

Application $app

Return Value

void

in ServiceProvider at line 55
protected void mergeConfigFrom(string $path, string $key)

Merge the given configuration with the existing configuration.

Parameters

string $path
string $key

Return Value

void

in ServiceProvider at line 68
protected void loadRoutesFrom(string $path)

Load the given routes file if routes are not already cached.

Parameters

string $path

Return Value

void

in ServiceProvider at line 82
protected void loadViewsFrom(string $path, string $namespace)

Register a view file namespace.

Parameters

string $path
string $namespace

Return Value

void

in ServiceProvider at line 98
protected void loadTranslationsFrom(string $path, string $namespace)

Register a translation file namespace.

Parameters

string $path
string $namespace

Return Value

void

in ServiceProvider at line 109
protected void loadMigrationsFrom(array|string $paths)

Register a database migration path.

Parameters

array|string $paths

Return Value

void

in ServiceProvider at line 125
protected void publishes(array $paths, string $group = null)

Register paths to be published by the publish command.

Parameters

array $paths
string $group

Return Value

void

in ServiceProvider at line 142
protected void ensurePublishArrayInitialized(string $class)

Ensure the publish array for the service provider is initialized.

Parameters

string $class

Return Value

void

in ServiceProvider at line 156
protected void addPublishGroup(string $group, array $paths)

Add a publish group / tag to the service provider.

Parameters

string $group
array $paths

Return Value

void

in ServiceProvider at line 174
static array pathsToPublish(string $provider = null, string $group = null)

Get the paths to publish.

Parameters

string $provider
string $group

Return Value

array

in ServiceProvider at line 192
static protected array pathsForProviderOrGroup(string|null $provider, string|null $group)

Get the paths for the provider or group (or both).

Parameters

string|null $provider
string|null $group

Return Value

array

in ServiceProvider at line 212
static protected array pathsForProviderAndGroup(string $provider, string $group)

Get the paths for the provider and group.

Parameters

string $provider
string $group

Return Value

array

in ServiceProvider at line 227
void commands(array|mixed $commands)

Register the package's custom Artisan commands.

Parameters

array|mixed $commands

Return Value

void

in ServiceProvider at line 241
array provides()

Get the services provided by the provider.

Return Value

array

in ServiceProvider at line 251
array when()

Get the events that trigger this service provider to register.

Return Value

array

in ServiceProvider at line 261
bool isDeferred()

Determine if the provider is deferred.

Return Value

bool

in ServiceProvider at line 273
static array compiles() deprecated

deprecated

Get a list of files that should be compiled for the package.

Return Value

array

at line 15
void register()

Register the service provider.

Return Value

void

at line 27
Writer createLogger()

Create the logger.

Return Value

Writer

at line 47
protected string channel()

Get the name of the log "channel".

Return Value

string

at line 58
protected void configureHandler(Writer $log)

Configure the Monolog handlers for the application.

Parameters

Writer $log

Return Value

void

at line 69
protected void configureSingleHandler(Writer $log)

Configure the Monolog handlers for the application.

Parameters

Writer $log

Return Value

void

at line 83
protected void configureDailyHandler(Writer $log)

Configure the Monolog handlers for the application.

Parameters

Writer $log

Return Value

void

at line 97
protected void configureSyslogHandler(Writer $log)

Configure the Monolog handlers for the application.

Parameters

Writer $log

Return Value

void

at line 108
protected void configureErrorlogHandler(Writer $log)

Configure the Monolog handlers for the application.

Parameters

Writer $log

Return Value

void

at line 118
protected string handler()

Get the default log handler.

Return Value

string

at line 132
protected string logLevel()

Get the log level for the application.

Return Value

string

at line 146
protected int maxFiles()

Get the maximum number of log files for the application.

Return Value

int