subscriptionid

package
v0.1.8 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2024 License: CC0-1.0 Imports: 4 Imported by: 1

Documentation

Index

Constants

View Source
const StdHRP = "su"
View Source
const StdLen = 14

Variables

This section is empty.

Functions

This section is empty.

Types

type T

type T struct {
	T B
}

func New

func New[V S | B](s V) (*T, error)

New inspects a string and converts to T if it is valid. Invalid means length == 0 or length > 64.

func NewStd

func NewStd() (t *T)

func (*T) IsValid

func (si *T) IsValid() bool

IsValid returns true if the subscription id is between 1 and 64 characters. Invalid means too long or not present.

func (*T) MarshalJSON

func (si *T) MarshalJSON(dst B) (b B, err error)

func (*T) String

func (si *T) String() S

func (*T) UnmarshalJSON

func (si *T) UnmarshalJSON(b B) (r B, err error)

Jump to

Keyboard shortcuts

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