> -----Original Message-----
> From: Kai Meder [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, April 11, 2007 12:27 PM
> To: [email protected]
> Subject: [fw-general] Zend_Log
> 
> hello,
> 
> it seems that the whole Zend_Log-docs are messed up:
>
<http://framework.zend.com/manual/en/zend.log.html#zend.log.overview.log
gi
> ng-messages>

Hi Kai,

Are you looking at the current docs online but using an earlier version
of Zend Framework?

The Zend_Log class and its subordinate classes are a new design that
moved to the core library in ZF 0.9.2.  The docs online describe the new
design.  If you are using ZF 0.9.1 or earlier, I can understand how the
docs may be confusing.  :-)

>  > $logger = new Zend_Log();
>  > $writer = new Zend_Log_Writer_Stream('php://output');
> private constructor

Neither constructor, for Zend_Log nor Zend_Log_Writer_Stream are private
in ZF 0.9.2.

>  > $logger->log('Informational message', Zend_Log::INFO);
> Zend_Log::LEVEL_INFO
> btw, why the LEVEL_ in the constant? just more typing-overhead...

The constant is Zend_Log::INFO in ZF 0.9.2.  You are using the old
constant.

> btw2, the java logging facility has convenience methods like
> Zend_Log::info(...
> Zend_Log::warn(...
> Zend_Log::debug(...

In ZF 0.9.2, those convenience methods are implemented, but not as
static methods.  You must call them on an object instance of type
Zend_Log.

Regards,
Bill Karwin

Reply via email to