converter

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2024 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ASCIIToIntPtr

func ASCIIToIntPtr(value string) (*int, error)

ASCIIToIntPtr Convert a string to an Int Pointer

func AccountLicenseType

func AccountLicenseType(accountLicenseTypeValue string) (*licensing.AccountLicenseType, error)

AccountLicenseType Get a pointer to an AccountLicenseType

func AccountLicensingSource

func AccountLicensingSource(licensingSourceValue string) (*licensing.LicensingSource, error)

AccountLicensingSource convert a string value to a licensing.AccountLicenseType pointer

func Bool

func Bool(value bool) *bool

Bool Get a pointer to a boolean value

func DecodeUtf16HexString

func DecodeUtf16HexString(message string) (string, error)

DecodeUtf16HexString decodes a binary representation of an UTF16 string

func EncodeUtf16HexString

func EncodeUtf16HexString(message string) (string, error)

EncodeUtf16HexString encodes a string into an binary representation with UTF16 enoding

func Int

func Int(value int) *int

Int Get a pointer to an integer value

func String

func String(value string) *string

String Get a pointer to a string

func StringFromInterface

func StringFromInterface(value interface{}) *string

StringFromInterface get a string pointer from an interface

func ToBool

func ToBool(value *bool, defaultValue bool) bool

ToBool Given a pointer return its value, or a default value of the pointer is nil

func ToPtr

func ToPtr[E any](e E) *E

func ToString

func ToString(value *string, defaultValue string) string

ToString Given a pointer return its value, or a default value of the pointer is nil

func UInt64

func UInt64(value uint64) *uint64

UInt64 Get a pointer to an uint64 value

func UUID

func UUID(szuuid string) *uuid.UUID

UUID converts a string to a pointer to a UUID, will panic if the string can't be parsed to a UUID

Types

This section is empty.

Jump to

Keyboard shortcuts

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