Net_MAC::format() | setMAC() |
Net_MAC | |
PEAR Manual | |
require_once 'Net/MAC.php'; |
Net_MAC::__construct (
object $db
, array $options
)
This is the constructor that will create and populate a valid Net_MAC object.
object $db - This parameter must be a valid MDB2 object.
array $options - An array of options to use with the database in retrieving MAC address vendors. The associative array should have key/value pairs as follows:
Option | Description |
tablename | The name of the table where MAC address vendor information lives |
macaddrcol | The name of the column containing the MAC address prefixes |
vendorcol | The name of the column containing the vendor name |
desccol | The name of the column containing any extra descriptive information derived from the vendor list |
void - No return value. A Net_MAC_Exception Exception object will be thrown if there is an error during construction
The constructor can throw exceptions on error, so the constructor should always be called from inside a try/catch block.
Instantiating a Net_MAC object
|
throws Net_MAC_Exception
Net_MAC::format() | setMAC() |
Net_MAC | |
PEAR Manual | |