net

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 12, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package net provides the network API types.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func EqualIPPrefixes

func EqualIPPrefixes(a, b IPPrefix) bool

Types

type IP

type IP struct {
	netip.Addr `json:"-"`
}

IP is an IP address. +k8s:openapi-gen=true

func MustParseIP

func MustParseIP(s string) IP

func MustParseNewIP

func MustParseNewIP(s string) *IP

func NewIP

func NewIP(ip netip.Addr) IP

func NewIPPtr

func NewIPPtr(ip netip.Addr) *IP

func ParseIP

func ParseIP(s string) (IP, error)

func ParseNewIP

func ParseNewIP(s string) (*IP, error)

func PtrToIP

func PtrToIP(addr IP) *IP

func (*IP) DeepCopy

func (in *IP) DeepCopy() *IP

func (*IP) DeepCopyInto

func (in *IP) DeepCopyInto(out *IP)

func (IP) Family

func (i IP) Family() v1.IPFamily

func (IP) GomegaString

func (i IP) GomegaString() string

func (*IP) IsValid

func (i *IP) IsValid() bool

func (*IP) IsZero

func (i *IP) IsZero() bool

func (IP) MarshalJSON

func (i IP) MarshalJSON() ([]byte, error)

func (IP) OpenAPIModelName added in v0.4.0

func (in IP) OpenAPIModelName() string

OpenAPIModelName returns the OpenAPI model name for this type.

func (IP) OpenAPISchemaFormat

func (i IP) OpenAPISchemaFormat() string

func (IP) OpenAPISchemaType

func (i IP) OpenAPISchemaType() []string

func (IP) ToUnstructured

func (i IP) ToUnstructured() interface{}

func (*IP) UnmarshalJSON

func (i *IP) UnmarshalJSON(b []byte) error

type IPPrefix

type IPPrefix struct {
	netip.Prefix `json:"-"`
}

IPPrefix represents a network prefix. +k8s:openapi-gen=true +nullable

func MustParseIPPrefix

func MustParseIPPrefix(s string) IPPrefix

func MustParseNewIPPrefix

func MustParseNewIPPrefix(s string) *IPPrefix

func NewIPPrefix

func NewIPPrefix(prefix netip.Prefix) *IPPrefix

func ParseIPPrefix

func ParseIPPrefix(s string) (IPPrefix, error)

func ParseNewIPPrefix

func ParseNewIPPrefix(s string) (*IPPrefix, error)

func PtrToIPPrefix

func PtrToIPPrefix(prefix IPPrefix) *IPPrefix

func (*IPPrefix) DeepCopy

func (in *IPPrefix) DeepCopy() *IPPrefix

func (*IPPrefix) DeepCopyInto

func (in *IPPrefix) DeepCopyInto(out *IPPrefix)

func (IPPrefix) GomegaString

func (i IPPrefix) GomegaString() string

func (IPPrefix) IP

func (i IPPrefix) IP() IP

func (*IPPrefix) IsValid

func (in *IPPrefix) IsValid() bool

func (*IPPrefix) IsZero

func (in *IPPrefix) IsZero() bool

func (IPPrefix) MarshalJSON

func (i IPPrefix) MarshalJSON() ([]byte, error)

func (IPPrefix) OpenAPIModelName added in v0.4.0

func (in IPPrefix) OpenAPIModelName() string

OpenAPIModelName returns the OpenAPI model name for this type.

func (IPPrefix) OpenAPISchemaFormat

func (in IPPrefix) OpenAPISchemaFormat() string

func (IPPrefix) OpenAPISchemaType

func (in IPPrefix) OpenAPISchemaType() []string

func (IPPrefix) ToUnstructured

func (i IPPrefix) ToUnstructured() interface{}

func (*IPPrefix) UnmarshalJSON

func (i *IPPrefix) UnmarshalJSON(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL