type alias ClassifiedAddressv6

Result of classifying an IPv6 address.

Contains the parsed value, the kind discriminant "ipv6", and the classification label from Classificationv6.

Examples

Example 1

import { assertEquals } from "@std/assert";
import { classifyAddress } from "@hertzg/ip/classify";
import { parseAddressv6 } from "@hertzg/ip/addressv6";

const result = classifyAddress(parseAddressv6("fe80::1").address);
assertEquals(result.kind, "ipv6");
assertEquals(result.classification, "link-local");

Properties

readonly
kind: "ipv6"
readonly
value: bigint

Usage

import { type ClassifiedAddressv6 } from "classify.ts";