ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> pear-dev
pear-dev
[PEAR-DEV] [PEPr] +1 for Networking::Net_MAC
by Justin Patrin other posts by this author
Dec 13 2006 11:23AM messages near this date
[PEAR-DEV] Re: [PEPr] +1 for Networking::Net_MAC | [PEAR-DEV] [PEPr] +1 for Networking::Net_MAC
Justin Patrin (http://pear.php.net/user/justinpatrin) has voted +1 on the proposal for Netwo
rking::Net_MAC.

Proposal information:
http://pear.php.net/pepr/pepr-proposal-show.php?id=454
Vote information:
http://pear.php.net/pepr/pepr-vote-show.php?id=454&handle=justinpatrin

This vote is conditional. The condition is:

You need to make your own Exception class which extends PEAR_Exception.
class Net_MAC_Exception extends PEAR_Exception {}
and use this exception for all of your throwing.

Don't throw, catch, and rethrow an exception:
        try {
            if (!is_a($db, 'MDB2_Driver_Common')) {
                throw new PEAR_Exception('Bad database object');
            }
        } catch (PEAR_Exception $e) {
            throw $e;
        }
The try/catch here is a no-op, it does nothing useful.

There is no need for =& when setting an object in PHP5.
$this-> _db =& $db;
changed to
$this-> _db = $db;

You need spaces around the = sign for default parameters.
static function check($input, $delimiter=':')
changed to
static function check($input, $delimiter = ':')

require_once 'MDB2.php'; should not be needed in importVendors of findVendor. The object is 
already in $this-> _db.

-- 
Sent by PEPr, the automatic proposal system at http://pear.php.net

-- 
PEAR Development Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Thread:
Andrew Teixeira
Greg Beaver
Andrew Teixeira
Justin Patrin
Christian Weiske
Andrew Teixeira
Andrew Teixeira
Arnaud Limbourg
Justin Patrin
Andrew Teixeira
Andrew Teixeira
Andrew Teixeira
Stefan Neufeind
Arnaud Limbourg
Justin Patrin
Graham Christensen

Privacy Policy | Email Opt-out | Feedback | Syndication
© 2004 ActiveState, a division of Sophos All rights reserved