Module cloudi_ip_address

CloudI IP Address Parsing

.

Copyright © 2013-2021 Michael Truog

Version: 2.0.3 Dec 3 2021 17:15:35 ------------------------------------------------------------------------

Authors: Michael Truog (mjtruog at protonmail dot com).

Description

CloudI IP Address Parsing

Data Types

cidr_string()

cidr_string() = [48..57 | 46 | 97..102 | 58 | 47, ...]

format_binary()

format_binary() = <<_:8, _:_*8>>

IPv4 dotted decimal address (no octal or hex) IPv6 lowercase hex with colons

format_string()

format_string() = [48..57 | 46 | 97..102 | 58 | 37, ...]

Function Index

from_binary/1

Parse a binary string representation.

.
from_string/1

Parse a binary string representation.

.
patterns/1

Create service name pattern strings that represent a CIDR (Classless Inter-Domain Routing) notation string.

Usage of the resulting patterns requires at least 1 suffix letter in the service name pattern string created with each pattern (i.e., each pattern wouldn't be used as a suffix).
to_binary/1

Create a binary string representation.

IPv6 doesn't shorten a group of zeroes so more exact pattern matches are possible in service names.
to_string/1

Create a list string representation.

IPv6 doesn't shorten a group of zeroes so more exact pattern matches are possible in service names.

Function Details

from_binary/1

from_binary(BinaryIP::format_binary()) -> inet:ip_address()

Parse a binary string representation.

from_string/1

from_string(StringIP::format_string()) -> inet:ip_address()

Parse a binary string representation.

patterns/1

patterns(CIDR::cidr_string()) -> [cloudi:service_name_pattern(), ...]

Create service name pattern strings that represent a CIDR (Classless Inter-Domain Routing) notation string.

Usage of the resulting patterns requires at least 1 suffix letter in the service name pattern string created with each pattern (i.e., each pattern wouldn't be used as a suffix).

to_binary/1

to_binary(IP::inet:ip_address()) -> format_binary()

Create a binary string representation.

IPv6 doesn't shorten a group of zeroes so more exact pattern matches are possible in service names.

to_string/1

to_string(X1::inet:ip_address()) -> format_string()

Create a list string representation.

IPv6 doesn't shorten a group of zeroes so more exact pattern matches are possible in service names.


Generated by EDoc