View Source Inet (Inet.ex v1.7.7)

Documentation for Inet.

Summary

Functions

A function that takes a ip address and returns a list of dns.

A convenience function that calls :inet.gethostbyaddr.

A convenience function that calls :inet.gethostbyname.

A function that takes a hostname and returns a list of IP addresses. The IP address in the result may vary as it depends on the network and DNS resolution.

Functions

Link to this function

get_dns_list(ip_address)

View Source

A function that takes a ip address and returns a list of dns.

Examples

iex> Inet.get_dns_list("172.217.27.46")
Link to this function

get_host_by_addr(ip_address)

View Source

A convenience function that calls :inet.gethostbyaddr.

Examples

iex> Inet.get_host_by_addr("172.217.27.46")
Link to this function

get_host_by_name(hostname)

View Source

A convenience function that calls :inet.gethostbyname.

Examples

iex> Inet.get_host_by_name("google.com")
Link to this function

get_ip_address_list(hostname)

View Source

A function that takes a hostname and returns a list of IP addresses. The IP address in the result may vary as it depends on the network and DNS resolution.

Examples

iex> Inet.get_ip_address_list("google.com")