메소드 | 설명 | |
---|---|---|
__construct ( Psr\Log\LoggerInterface $logger ) | Set the LoggerInterface instance. | |
__invoke ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response, callable $next ) : Psr\Http\Message\ResponseInterface | Execute the middleware. | |
combined ( boolean $combined = true ) : self | Whether use the combined log format instead the common log format. |
메소드 | 설명 | |
---|---|---|
combinedFormat ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response ) : string | Generates a message using the Apache's Combined Log format This is exactly the same than Common Log, with the addition of two more fields: Referer and User-Agent headers. | |
commonFormat ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response ) : string | Generates a message using the Apache's Common Log format https://httpd.apache.org/docs/2.4/logs.html#accesslog. |
public __construct ( Psr\Log\LoggerInterface $logger ) | ||
$logger | Psr\Log\LoggerInterface |
public __invoke ( Psr\Http\Message\ServerRequestInterface $request, Psr\Http\Message\ResponseInterface $response, callable $next ) : Psr\Http\Message\ResponseInterface | ||
$request | Psr\Http\Message\ServerRequestInterface | |
$response | Psr\Http\Message\ResponseInterface | |
$next | callable | |
리턴 | Psr\Http\Message\ResponseInterface |