PHP Class Eccube\EventListener\RequestDumpListener

ログ出力を除外したいキーは log.yml の exclude_keys で設定します. addExcludeKey(), removeExcludeKey() でも設定できます.
Author: Kentaro Ohkouchi
Inheritance: implements Symfony\Component\EventDispatcher\EventSubscriberInterface
Show file Open project: ec-cube/ec-cube

Public Methods

Method Description
__construct ( Application $app ) Constructor function.
getSubscribedEvents ( ) : array Return the events to subscribe to.
onKernelRequest ( GetResponseEvent $event ) Kernel request listener callback.
onResponse ( FilterResponseEvent $event ) Kernel response listener callback.

Protected Methods

Method Description
addExcludeKey ( string $key ) ログ出力を除外するキーを追加します.
logArray ( array $values, $prefix = '' ) 配列をログ出力する.
logKeyValuePair ( $key, $value, $prefix = '' ) キーと値のペアをログ出力する.
logRequest ( Request $request ) : string Request のログを出力する.
logResponse ( Response $response ) : string Response のログを出力する.
logSession ( Symfony\Component\HttpFoundation\Session\SessionInterface $Session ) Session のログを出力する.
removeExcludeKey ( string $key ) ログ出力を除外するキーを削除します.

Method Details

__construct() public method

Constructor function.
public __construct ( Application $app )
$app Eccube\Application

addExcludeKey() protected method

ログ出力を除外するキーを追加します.
protected addExcludeKey ( string $key )
$key string 除外対象のキー

getSubscribedEvents() public static method

Return the events to subscribe to.
public static getSubscribedEvents ( ) : array
return array

logArray() protected method

配列をログ出力する.
protected logArray ( array $values, $prefix = '' )
$values array

logKeyValuePair() protected method

除外キーに該当する値は, マスクをかける
protected logKeyValuePair ( $key, $value, $prefix = '' )

logRequest() protected method

Request のログを出力する.
protected logRequest ( Request $request ) : string
$request Symfony\Component\HttpFoundation\Request
return string Request のログ

logResponse() protected method

Response のログを出力する.
protected logResponse ( Response $response ) : string
$response Symfony\Component\HttpFoundation\Response
return string Response のログ

logSession() protected method

Session のログを出力する.
protected logSession ( Symfony\Component\HttpFoundation\Session\SessionInterface $Session )
$Session Symfony\Component\HttpFoundation\Session\SessionInterface

onKernelRequest() public method

Kernel request listener callback.
public onKernelRequest ( GetResponseEvent $event )
$event Symfony\Component\HttpKernel\Event\GetResponseEvent

onResponse() public method

Kernel response listener callback.
public onResponse ( FilterResponseEvent $event )
$event Symfony\Component\HttpKernel\Event\FilterResponseEvent

removeExcludeKey() protected method

ログ出力を除外するキーを削除します.
protected removeExcludeKey ( string $key )
$key string 削除対象のキー