[dev] Driver capability assertions

Brent J. Nordquist bjn@horde.org
Sat, 17 Feb 2001 10:33:25 -0600 (CST)


On Fri, 16 Feb 2001, Rich Lafferty <rich@horde.org> wrote:

> >     if (!function_exists('ldap_connect')) {
> >         echo 'LDAP support is required by this driver.';
> >         exit;
> >     }
>
> I like this. :-)

So do I.  What about a facility in the Horde framework to provide this; a
Horde function that could be called to check on a mandatory capability,
produce a suitable error message, and exit.  (Could it check on whether
the headers have been sent or not?)  But that way the code to check would
be clean (a one-liner).

-- 
Brent J. Nordquist <bjn@horde.org>
Yahoo!: Brent_Nordquist / AIM: BrentJNordquist / ICQ: 76158942