Overview

Namespaces

  • Charcoal
    • App
      • Action
      • Config
      • Handler
      • Middleware
      • Module
      • Route
      • Script
      • ServiceProvider
      • Template

Classes

  • Charcoal\App\Action\AbstractAction
  • Charcoal\App\App
  • Charcoal\App\AppConfig
  • Charcoal\App\AppContainer
  • Charcoal\App\Config\CacheConfig
  • Charcoal\App\Config\DatabaseConfig
  • Charcoal\App\Config\FilesystemConfig
  • Charcoal\App\Config\LoggerConfig
  • Charcoal\App\Config\MemcacheCacheConfig
  • Charcoal\App\Config\MemcacheCacheServerConfig
  • Charcoal\App\Handler\AbstractHandler
  • Charcoal\App\Handler\Error
  • Charcoal\App\Handler\HandlerConfig
  • Charcoal\App\Handler\NotAllowed
  • Charcoal\App\Handler\NotFound
  • Charcoal\App\Handler\PhpError
  • Charcoal\App\Handler\Shutdown
  • Charcoal\App\Middleware\CacheMiddleware
  • Charcoal\App\Module\AbstractModule
  • Charcoal\App\Module\ModuleConfig
  • Charcoal\App\Module\ModuleManager
  • Charcoal\App\Route\ActionRoute
  • Charcoal\App\Route\ActionRouteConfig
  • Charcoal\App\Route\RouteConfig
  • Charcoal\App\Route\RouteManager
  • Charcoal\App\Route\ScriptRoute
  • Charcoal\App\Route\ScriptRouteConfig
  • Charcoal\App\Route\TemplateRoute
  • Charcoal\App\Route\TemplateRouteConfig
  • Charcoal\App\Script\AbstractScript
  • Charcoal\App\ServiceProvider\AppServiceProvider
  • Charcoal\App\ServiceProvider\CacheServiceProvider
  • Charcoal\App\ServiceProvider\DatabaseServiceProvider
  • Charcoal\App\ServiceProvider\FilesystemServiceProvider
  • Charcoal\App\ServiceProvider\LoggerServiceProvider
  • Charcoal\App\ServiceProvider\ViewServiceProvider
  • Charcoal\App\Template\AbstractTemplate
  • Charcoal\App\Template\AbstractWidget
  • Charcoal\App\Template\WidgetBuilder

Interfaces

  • Charcoal\App\Action\ActionInterface
  • Charcoal\App\AppAwareInterface
  • Charcoal\App\Handler\HandlerInterface
  • Charcoal\App\Module\ModuleInterface
  • Charcoal\App\Route\RouteInterface
  • Charcoal\App\Script\CronScriptInterface
  • Charcoal\App\Script\ScriptInterface
  • Charcoal\App\Template\TemplateInterface
  • Charcoal\App\Template\WidgetInterface

Traits

  • Charcoal\App\AppAwareTrait
  • Charcoal\App\CallableResolverAwareTrait
  • Charcoal\App\Script\ArgScriptTrait
  • Charcoal\App\Script\CronScriptTrait
  • Charcoal\App\Script\PathScriptTrait
  • Overview
  • Namespace
  • Class
  1: <?php
  2: 
  3: namespace Charcoal\App\Config;
  4: 
  5: // Module `charcoal-config` dependencies
  6: use \Charcoal\Config\AbstractConfig;
  7: 
  8: /**
  9:  *
 10:  */
 11: class LoggerConfig extends AbstractConfig
 12: {
 13:     /**
 14:      * @var boolean $active
 15:      */
 16:     private $active;
 17: 
 18:     /**
 19:      * @var array $handlers
 20:      */
 21:     private $handlers;
 22: 
 23:     /**
 24:      * @var array $processors
 25:      */
 26:     private $processors;
 27: 
 28:     /**
 29:      * @return array
 30:      */
 31:     public function defaults()
 32:     {
 33:         return [
 34:             'active' => true,
 35:             'namespace' => 'Charcoal',
 36:             'level'     => 'debug',
 37:             'handlers' => [
 38:                 'stream' => [
 39:                     'type'      => 'stream',
 40:                     'stream'    => '../charcoal.app.log',
 41:                     'level'     => null,
 42:                     'bubble'    => true,
 43:                     'active'    => true
 44:                 ],
 45:                 'console' => [
 46:                     'type'      => 'browser-console',
 47:                     'level'     => null,
 48:                     'active'    => false
 49:                 ]
 50:             ],
 51:             'processors' => [
 52:                 [
 53:                     'type' => 'memory-usage'
 54:                 ],
 55:                 [
 56:                     'type' => 'uid'
 57:                 ]
 58:             ]
 59:         ];
 60:     }
 61: 
 62:     /**
 63:      * @param boolean $active The active flag.
 64:      * @return LoggerConfig Chainable
 65:      */
 66:     public function setActive($active)
 67:     {
 68:         $this->active = !!$active;
 69:         return $this;
 70:     }
 71: 
 72:     /**
 73:      * @return boolean
 74:      */
 75:     public function active()
 76:     {
 77:         return $this->active;
 78:     }
 79: 
 80:     /**
 81:      * @param array $handlers The (monolog) logger handlers.
 82:      * @return LoggerConfig Chainable
 83:      */
 84:     public function setHandlers(array $handlers)
 85:     {
 86:         $this->handlers = $handlers;
 87:         return $this;
 88:     }
 89: 
 90:     /**
 91:      * @return array
 92:      */
 93:     public function handlers()
 94:     {
 95:         return $this->handlers;
 96:     }
 97: 
 98:     /**
 99:      * @param array $processors The (monolog) logger processors.
100:      * @return LoggerConfig Chainable
101:      */
102:     public function setProcessors(array $processors)
103:     {
104:         $this->processors = $processors;
105:         return $this;
106:     }
107: 
108:     /**
109:      * @return array
110:      */
111:     public function processors()
112:     {
113:         return $this->processors;
114:     }
115: }
116: 
API documentation generated by ApiGen