Overview

Namespaces

  • None
  • RedBeanPHP
    • Adapter
    • BeanHelper
    • Cursor
    • Driver
    • Logger
      • RDefault
    • QueryWriter
    • RedException
    • Repository
    • Util

Classes

  • RDefault
  • Overview
  • Namespace
  • Class

Class RDefault

Logger. Provides a basic logging function for RedBeanPHP.

RedBeanPHP\Logger\RDefault implements RedBeanPHP\Logger

Direct known subclasses

RedBeanPHP\Logger\RDefault\Debug
Namespace: RedBeanPHP\Logger
Copyright:

copyright (c) G.J.G.T. (Gabor) de Mooij This source file is subject to the BSD/GPLv2 License that is bundled with this source code in the file license.txt.


License: BSD/GPLv2
Author: Gabor de Mooij and the RedBeanPHP Community
File: RedBeanPHP/Logger.php
Located at Logger/RDefault.php
Methods summary
public
# log( $message,… )

Default logger method logging to STDOUT. This is the default/reference implementation of a logger. This method will write the message value to STDOUT (screen) unless you have changed the mode of operation to C_LOGGER_ARRAY.

Default logger method logging to STDOUT. This is the default/reference implementation of a logger. This method will write the message value to STDOUT (screen) unless you have changed the mode of operation to C_LOGGER_ARRAY.

Parameters

$message,…
message to log (might also be data or output)

Implementation of

RedBeanPHP\Logger::log()
public array
# getLogs( )

Returns the internal log array. The internal log array is where all log messages are stored.

Returns the internal log array. The internal log array is where all log messages are stored.

Returns

array
public RedBeanPHP\Logger\RDefault
# clear( )

Clears the internal log array, removing all previously stored entries.

Clears the internal log array, removing all previously stored entries.

Returns

RedBeanPHP\Logger\RDefault
public RedBeanPHP\Logger\RDefault
# setMode( integer $mode )

Selects a logging mode. There are several options available.

Selects a logging mode. There are several options available.

  • C_LOGGER_ARRAY - log silently, stores entries in internal log array only
  • C_LOGGER_ECHO - also forward log messages directly to STDOUT

Parameters

$mode
mode of operation for logging object

Returns

RedBeanPHP\Logger\RDefault
public array
# grep( string $needle )

Searches for all log entries in internal log array for $needle and returns those entries. This method will return an array containing all matches for your search query.

Searches for all log entries in internal log array for $needle and returns those entries. This method will return an array containing all matches for your search query.

Parameters

$needle
phrase to look for in internal log array

Returns

array
Constants summary
integer C_LOGGER_ECHO

Logger modes

Logger modes

# 0
integer C_LOGGER_ARRAY
# 1
Properties summary
protected integer $mode
# 0
protected array $logs
# array()
API documentation generated by ApiGen