Modules

Log_StdOut
extends Kohana_Log_StdOut
extends Log_Writer
extends Kohana_Log_Writer

STDOUT log writer. Writes out messages to STDOUT.

package
Kohana
category
Logging
author
Kohana Team
copyright
© 2008-2012 Kohana Team
license
http://kohanaphp.com/license

Class declared in SYSPATH/classes/log/stdout.php on line 3.

Constants

  • None

Properties

Properties

protected array $_log_levels

Methods

public write( array $messages ) (defined in Kohana_Log_StdOut)

Writes each of the messages to STDOUT.

$writer->write($messages);

Parameters

  • array $messages required - $messages

Return Values

  • void

Source Code

public function write(array $messages)
{
	// Set the log line format
	$format = 'time --- type: body';

	foreach ($messages as $message)
	{
		// Writes out each message
		fwrite(STDOUT, PHP_EOL.strtr($format, $message));
	}
}

final public __toString( ) (defined in Kohana_Log_Writer)

Allows the writer to have a unique key when stored.

echo $writer;

Return Values

  • string

Source Code

final public function __toString()
{
	return spl_object_hash($this);
}