Error log
2017-11-25T00:19:20+00:00 ERR (3): Test error log message!
2017-11-25T00:19:20+00:00 CRIT (2): Test critical log message!
2017-11-25T00:19:20+00:00 ALERT (1): Test alert log message!
2017-11-25T00:19:20+00:00 EMERG (0): Test emergency log message!
Application log
2017-11-25T00:19:20+00:00 INFO (6): Event bootstrap
2017-11-25T00:19:20+00:00 INFO (6): Event configure
2017-11-25T00:19:20+00:00 INFO (6): Configuring application
2017-11-25T00:19:20+00:00 INFO (6): Attaching aggregate listener [object WebinoAppLib\Listener\DebuggerListener]
2017-11-25T00:19:20+00:00 INFO (6): Attaching aggregate listener [object WebinoAppLib\Listener\ContextListener]
2017-11-25T00:19:20+00:00 INFO (6): Event bootstrap
2017-11-25T00:19:20+00:00 INFO (6): Matching context WebinoAppLib\Context\HttpContext
2017-11-25T00:19:20+00:00 INFO (6): Attaching aggregate listener [object WebinoAppLib\Listener\Http\HttpRoutingListener]
2017-11-25T00:19:20+00:00 INFO (6): Attaching aggregate listener [object WebinoAppLib\Listener\Http\HttpRequestListener]
2017-11-25T00:19:20+00:00 INFO (6): Attaching aggregate listener [object WebinoAppLib\Listener\Http\HttpResponseListener]
2017-11-25T00:19:20+00:00 INFO (6): Event WebinoAppLib\Event\ContextEvent
2017-11-25T00:19:20+00:00 ERR (3): Test error log message!
2017-11-25T00:19:20+00:00 CRIT (2): Test critical log message!
2017-11-25T00:19:20+00:00 ALERT (1): Test alert log message!
2017-11-25T00:19:20+00:00 EMERG (0): Test emergency log message!
2017-11-25T00:19:20+00:00 INFO (6): Attaching [object Closure] to an event WebinoAppLib\Router\DefaultRoute with priority 1
2017-11-25T00:19:20+00:00 INFO (6): Event dispatch
2017-11-25T00:19:20+00:00 INFO (6): Attaching [object Closure] to an event routeMatch with priority 1
2017-11-25T00:19:20+00:00 INFO (6): Event routeMatch
2017-11-25T00:19:20+00:00 INFO (6): Event WebinoAppLib\Router\DefaultRoute
Source Preview
<?php
/**
 * Logger Filters
 * Webino Example
 */

use WebinoAppLib\Event\RouteEvent;
use 
WebinoAppLib\Response\Content\SourcePreview;
use 
WebinoAppLib\Router\DefaultRoute;
use 
WebinoExamplesLib\Html\FieldSetScrollBox;
use 
WebinoConfigLib\Feature\Log;

require 
__DIR__ '/../../vendor/autoload.php';

/**
 * Example logs
 */
abstract class MyLogs
{
    const 
APP 'app.log';
    const 
ERROR 'error.log';
}

$config Webino::config([
    
/**
     * Configuring app and error log
     * with priority filters.
     */
    
(new Log(MyLogs::APP))->filterPriority(Log::INFO),
    (new 
Log(MyLogs::ERROR))->filterPriority(Log::ERROR),
]);

$app Webino::application($config)->bootstrap();

/**
 * Writing log
 * messages.
 */
$app->log()->error('Test error log message!');
$app->log()->critical('Test critical log message!');
$app->log()->alert('Test alert log message!');
$app->log()->emergency('Test emergency log message!');

$app->bind(DefaultRoute::class, function (RouteEvent $event) {
    
/**
     * Obtaining log
     * files contents.
     */
    
$log $event->getApp()->file()->read(MyLogs::APP);
    
$errLog $event->getApp()->file()->read(MyLogs::ERROR);

    
$event->setResponse([
        new 
FieldSetScrollBox('Error log'$errLog),
        new 
FieldSetScrollBox('Application log'$log),
        new 
SourcePreview(__FILE__),
    ]);
});

$app->dispatch();