ugly

package
v0.0.0-...-d49a382 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UnsafeString

func UnsafeString(in []byte) string

UnsafeString returns a mutable "string" by raw casting the given byte slice.

This is primarily intended to do string "casts" without copying the underlying data.

This also means that the caller of this function takes full ownership of the backing byte slice and never passes that slice around while this "string" exists.

Types

type PseudoString

type PseudoString []byte

PseudoString is an unsafe string accessor over a mutable byte array.

This type should _never_ be exposed outside of the internal package of this library.

func (*PseudoString) AppendJSONBytes

func (p *PseudoString) AppendJSONBytes(buf io.Writer) (e error)

func (*PseudoString) IsNil

func (p *PseudoString) IsNil() bool

func (PseudoString) JSONSize

func (p PseudoString) JSONSize() uint32

func (PseudoString) MarshalJSON

func (p PseudoString) MarshalJSON() ([]byte, error)

func (PseudoString) String

func (p PseudoString) String() string

func (PseudoString) ToJSONBytes

func (p PseudoString) ToJSONBytes() []byte

func (*PseudoString) UnmarshalJSON

func (p *PseudoString) UnmarshalJSON(in []byte) error

Jump to

Keyboard shortcuts

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