<?php
/**
 * The interface for log writers.
 */
interface log_writer
{
    ////////////////////////////////////////////////////////////////////////////
    // Overload functions.
    
    ////////////////////////////////////////////////////////////////////////////
    // Interface functions.
    
    /**
     * Writes a log message to storage.
     *
     * @param string $message The message.
     * @param integer (optional) $priority The priority.
     * @param string (optional) $timestamp The date.
     * @return log_writer A fluent interface.
     */
    public function write($message, $priority = log::EMERGENCY, $timestamp = null);
}
