Fix for testthat deprecation warnings.
Fix for CRAN checks.
Fix for CRAN checks.
To mark the release of ipaddress 1.0.0, somebreakingchanges were made to improve the interface for dataanalysis.
multiple argument fromip_to_hostname() andhostname_to_ip() (#83).ip_to_hostname() andhostname_to_ip() nowalways return one result per input (stored in a vector).ip_to_hostname_all() andhostname_to_ip_all() return all results per input (storedin a list of vectors).subnets() now takes vector input and outputs a list ofvectors (#83).strict argument ofip_network().exploded argument offormat.ip_address(),format.ip_network() andformat.ip_interface().replace argument ofsample_ipv4(),sample_ipv6() andsample_network().country_networks() downloads IP networks registeredto specific countries (#87).is_ipv6 argument ofnetmask() andhostmask() defaults toNULL. This optionprefers an IPv4 mask, but creates an IPv6 mask as a fallback.vignette("ipaddress-classes") tovignette("ip-data").vignette("ipaddress-examples") tovignette("recipes").iana_ipv4 dataset.Fix for CRAN checks.
Fix for CRAN checks.
Fix for CRAN checks.
Fix for CRAN checks.
base argument ofip_to_integer() isremoved.base = "dec" is still handled byip_to_integer().base = "bin" is still handled by the existingip_to_binary() function.base = "hex" is now handled by the newip_to_hex() function.ip_to_integer() andinteger_to_ip() nowusebignum::biginteger() vectors to store IP addresses asintegers. Previously, these integers were stored in a character vector(because they were beyond the range of base R numeric types).ip_to_hex() andhex_to_ip() functionsto encode and decode addresses as hexadecimal strings.ip_to_bytes() now returns a list of raw vectors insteadof ablob object (#65).blob::as_blob().LinkingTo: ipaddresswithoutLinkingTo: AsioHeaders.This release achieves feature parity with the Pythonipaddressmodule (#46).
is_private(),is_reserved(),is_site_local() (#49).is_global() checks if addresses or networks arenot reserved (#49).collapse_networks() collapses contiguous andoverlapping networks (#54).exclude_networks() removes networks from others(#59).reverse_pointer() returns the record used byreverse DNS (#57).iana_ipv4 andiana_ipv6contain registries of allocated blocks (#55).%<<% and%>>% (#52).IpAddressVector andIpNetworkVector classes to other packages (useLinkingTo: AsioHeaders, ipaddress, Rcpp). This does notaffect the public R interface (#51).format.ip_address(),format.ip_network()andformat.ip_interface() gain anexplodedparameter to display leading zeros for IPv6 addresses (#56).ip_to_integer() gains abase parameter toselect between decimal, hexadecimal and binary outputs (#47).vignette("ipaddress-examples") to use thefuzzyjoinpackage (#61).vignette("ipaddress-examples") with how torandomly generate public IP addresses (#62).ip_address() vectors to account formachine endianness (#53).ip_network() andip_interface() vectors is now consistent with the Pythonipaddress module.ip_network(): network address compared before prefixlength.ip_interface(): network compared before hostaddress.ip_network() vectorswithout using CIDR notation.common_network() function finds the smallestnetwork containing two addresses (#39).summarize_address_range() function lists theconstituent networks of an address range (#41).prefix_length() can now infer the prefix length from anip_address() vector of netmasks and/or hostmasks. Thismakes it possible to construct anip_network() vector likeso: (#36)ip_network(ip_address("192.0.2.0"), prefix_length(ip_address("255.255.255.0"))).ip_network(ip_address("192.0.2.0"), prefix_length(ip_address("0.0.0.255"))).supernet() andsubnets() functions fortraversing the network hierarchy (#42).vignette("ipaddress-examples") to describe sometypical usage patterns (#43).integer_to_ip() now accepts integerish doubles.netmask() andhostmask() now raise anerror if theprefix_length andis_ipv6arguments are not both specified (#38).is_within_any() to correctly catch when IPv6addresses are in zero networks.vignette("ipaddress") asvignette("ipaddress-classes").as_packed() andfrom_packed() becomeip_to_bytes() andbytes_to_ip().as_binary() andfrom_binary() becomeip_to_binary() andbinary_to_ip().as_hostname() andfrom_hostname() becomeip_to_hostname() andhostname_to_ip().ip_to_integer() andinteger_to_ip()functions to encode and decode addresses as integers. Note that theintegers are contained within a character vector. Please see thefunction documentation for an explanation (#30).vignette("ipaddress") to introduce the dataclasses provided by ipaddress (#24).ip_interface() class to simultaneously store theaddress and the network it is on (#15).ip_address() vectors now support bitwise operations(!,&,| and^).ip_address() vectors now support addition andsubtraction of integers (#14).ip_network() constructor that acceptsip_address and prefix length vectors (#9).as_packed() andfrom_packed()functions to encode and decode addresses as raw bytes (#13).as_binary() andfrom_binary()functions to encode and decode addresses as binary strings (#18).as_hostname() andfrom_hostname()functions translate addresses to and from hostnames (#22).max_prefix_length() function to get the size of theaddress space (32-bit for IPv4 and 128-bit for IPv6).is_multicast(),is_unspecified(),is_loopback(),is_link_local().is_ipv4_mapped(),is_6to4(),is_teredo().extract_ipv4_mapped(),extract_6to4(),extract_teredo_server(),extract_teredo_client().num_addresses(),network_address() andbroadcast_address().overlaps() function to check foranyoverlap between networks.netmask() andhostmask() are now generics,so they can now accept:ip_network() vector (existing behavior).ip_interface() vector.seq.ip_network() andhosts() functionsto list all addresses within a network.sample_ipv4(),sample_ipv6() andsample_network() (#11, #19).NA.0.0.0.128.0:80::/32network.is_subnet() andis_supernet() now checkthe prefix length, to ensure they are a true subnet or supernet.Fix for CRAN checks.
First CRAN release
ip_address() andip_network()classes.vctrs package for full tidyversecompatibility.is_within() andis_within_any() check ifaddresses are within networks.is_subnet() andis_supernet() check ifnetworks are within other networks.is_ipv4() andis_ipv6() classify theaddress space.prefix_length(),netmask() andhostmask() yield different representations of the networkmask.Rcpp andAsioHeaders packages) for improved performance.