Re: cvs: php4 /pear DB.php
| From: | Stig Sæther Bakken | Date: | Wed, 26 Jul 2000 10:28:39 +0000 |
| Subject: | Re: cvs: php4 /pear DB.php | ||
| References: | 1 | Groups: | php.pear |
| Request: | Send a blank email to php-pear+get-168@lists.php.net to get a copy of this message | ||
David Croft wrote:
>
> Out of interest, can a constructor return false to have the "new" call
> return false? Or is there any way of achieving this?
>
> I was wondering about this when I added the if extension_loaded to the
> constructor of Payment_Verisign
I don't think there is a way of aborting a "new" in a constructor
without raising a fatal error (that would make the executor stop, so
it's sort of pointless). So anything that can fail will have to be done
in another method.
- Stig