mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Added PHPDoc for function isPingable()
This commit is contained in:
@@ -502,6 +502,15 @@ function isSNMPable($device) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check if the given host responds to ICMP echo requests ("pings").
|
||||||
|
*
|
||||||
|
* @param string $hostname The hostname or IP address to send ping requests to.
|
||||||
|
* @param int $address_family The address family (AF_INET for IPv4 or AF_INET6 for IPv6) to use. Defaults to IPv4. Will *not* be autodetected for IP addresses, so it has to be set to AF_INET6 when pinging an IPv6 address or an IPv6-only host.
|
||||||
|
* @param int $device_id This parameter is currently ignored.
|
||||||
|
*
|
||||||
|
* @return bool TRUE if the host responded to at least one ping request, FALSE otherwise.
|
||||||
|
*/
|
||||||
function isPingable($hostname,$address_family = AF_INET,$device_id = FALSE) {
|
function isPingable($hostname,$address_family = AF_INET,$device_id = FALSE) {
|
||||||
global $config;
|
global $config;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user