Linux SNMP driver.
More...
Public Member Functions |
| isCompactibleDriverWith ($device_ip) |
| Checks if the driver is compactible with the driver.
|
| getARPMacAddressOf ($device_ip) |
| Obtain MAC address of a device with the given IP address from ARP table.
|
| getDHCPMacAddressOf ($device_ip) |
| Obtain MAC address of a device with the given IP address from DHCP server.
|
| getPortNumberOf ($mac_address) |
| Obtaint port number with given MAC address.
|
| getTimeout () |
| Gets the current number of microseconds until the first timeout.
|
| setTimeout ($timeout) |
| Sets the number of microseconds until the first timeout.
|
| getRetries () |
| Gets the number of times to retry if timeouts occur.
|
| setRetries ($retries) |
| Sets the number of times to retry if timeouts occur.
|
| getComunity () |
| Gets the read community.
|
| setComunity ($comunity) |
| Sets the read community.
|
| setDeviceIp ($device_ip) |
| Sets device IP.
|
| getDeviceIp () |
| Gets device IP address.
|
| errorHandler ($errno, $errstr, $errfile, $errline) |
| Handles errors (throws exceptions)
|
Additional Inherited Members |
| startErrorHandler () |
| Starts handling PHP errors as Exceptions (if not already started)
|
| stopErrorHandler () |
| Stops handling PHP errors as Exceptions (if not alreasy stopped)
|
| $timeout = 3000000 |
| $retries = 5 |
| $comunity = 'public' |
| $error_handler_started = FALSE |
| $deviceIp |
Detailed Description
Linux SNMP driver.
This class MUST not be initialized directly, use Snmp_Factory!
- Author
- Ondrej Fibich
- See Also
- Abstract_Snmp
Member Function Documentation
Linux_Snmp::getARPMacAddressOf |
( |
|
$device_ip | ) |
|
Obtain MAC address of a device with the given IP address from ARP table.
- Parameters
-
string | $device_ip | IP address of the device (we would like to know his MAC) |
- Returns
- string MAC address in format xx:xx:xx:xx:xx:xx
- Exceptions
-
Exception | On SNMP error or wrong SNMP response |
InvalidArgumentException | On wrong IP address |
Reimplemented from Abstract_Snmp.
Linux_Snmp::getDHCPMacAddressOf |
( |
|
$device_ip | ) |
|
Obtain MAC address of a device with the given IP address from DHCP server.
- Parameters
-
string | $device_ip | IP address of the device (we would like to know his MAC) |
- Returns
- string MAC address in format xx:xx:xx:xx:xx:xx
- Exceptions
-
Exception | On SNMP error or wrong SNMP response |
InvalidArgumentException | On wrong IP address |
Reimplemented from Abstract_Snmp.
Linux_Snmp::getPortNumberOf |
( |
|
$mac_address | ) |
|
Obtaint port number with given MAC address.
- Parameters
-
string | $mac_address | MAC address of the device (we would like to know to which port is connected) |
- Returns
- string MAC address in format xx:xx:xx:xx:xx:xx
- Exceptions
-
Exception | On SNMP error or wrong SNMP response |
InvalidArgumentException | On wrong IP address |
Reimplemented from Abstract_Snmp.
Linux_Snmp::isCompactibleDriverWith |
( |
|
$device_ip | ) |
|
Checks if the driver is compactible with the driver.
- Parameters
-
string | $device_ip | Device IP address |
- Returns
- bool Is compactible?
Reimplemented from Abstract_Snmp.
The documentation for this class was generated from the following file: