Overview

Namespaces

  • gregoryv
    • logger

Classes

  • CachedWriter
  • ConsoleWriter
  • FileWriter
  • Logger
  • State
  • SyslogWriter

Interfaces

  • SeverityWriterInterface
  • Overview
  • Namespace
  • Class

Class CachedWriter

FIFO cache of log messages

gregoryv\logger\CachedWriter implements gregoryv\logger\SeverityWriterInterface
Namespace: gregoryv\logger
Located at CachedWriter.php
Methods summary
public
# __construct( $messageLimit = 20 )

Parameters

$messageLimit
many messages to keep in cache
public
# swrite( integer $severity, string $value = '' )

Stores messages in the public cache by priority

Stores messages in the public cache by priority

Parameters

$severity
eg. LOG_DEBUG, LOG_ERR
$value
$message the string to write

Implementation of

gregoryv\logger\SeverityWriterInterface::swrite()
public
# setLimit( integer $limit )

Parameters

$limit
public
# resizeCache( $limit )
Properties summary
public array $cache

$cache holding the messages

$cache holding the messages

#
API documentation generated by ApiGen