Structureswift-ip 0.3.0Firewalls->IP
Firewall
IP.Firewall.swift:9@frozen struct Firewall
@frozen struct Firewall
import Firewalls
import IP
This Foundation-free module provides tools for parsing and formatting IP addresses, and data structures for performing efficient IP address lookups.
@frozen enum IP
The namespace for IP types.
@frozen struct AS
Describes an Autonomous System (AS).
@frozen struct ASN
An Autonomous System Number (ASN).
@frozen enum Claimant
@frozen struct Table<Color> where Color : BSON.BinaryPackable
A data structure for efficient IP address lookups.
protocol Sendable
static func load(from image: Image, loopback: IP.Claimant? = nil) -> IP.Firewall
let asn: Table<ASN>
let country: Table<ISO.Country>
func lookup(v4 ip: IP.V4) -> (IP.AS?, IP.Claimant?)
func lookup(v6 ip: IP.V6) -> (IP.AS?, IP.Claimant?)
@frozen struct Image
The data used to construct IP.Firewall
.