Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Domain ¶
type Domain string
func FromString ¶
FromString creates a Domain from a string, converting it to punycode.
func (Domain) SafeString ¶
SafeString converts the Domain to a non-punycode string, falling back to the original string if conversion fails.
type List ¶
type List []Domain
func FromPunycodeList ¶
FromPunycodeList creates a List from a slice of Punycode-encoded domain strings.
func FromStringList ¶
FromStringList creates a DomainList from a slice of string.
func (List) PunycodeString ¶
PunycodeString converts the List to a comma-separated string of Punycode-encoded domains.
func (List) SafeString ¶
SafeString converts List to a comma-separated non-punycode string. If a domain cannot be converted, the original string is used.
func (List) ToPunycodeList ¶
ToPunycodeList converts the List to a slice of Punycode-encoded domain strings.
func (List) ToSafeStringList ¶
ToSafeStringList converts the List to a slice of non-punycode strings. If a domain cannot be converted, the original string is used.
func (List) ToStringList ¶
ToStringList converts a List to a slice of string.