binary

package module
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2022 License: BSD-3-Clause Imports: 1 Imported by: 11

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Binary

type Binary string

Binary wraps binary data and provides encoding helpers using base64.StdEncoding. Use this type for binary fields serialized/deserialized as base64 text. Type is specified as string rather than []byte so that it can be used as a map key. Use Bytes() to access the raw bytes. Values of this type are only valid when the backing string is Base64-encoded using standard encoding.

func New

func New(data []byte) Binary

func (Binary) Bytes

func (b Binary) Bytes() ([]byte, error)

func (Binary) MarshalText

func (b Binary) MarshalText() (text []byte, err error)

func (Binary) String

func (b Binary) String() string

func (*Binary) UnmarshalText

func (b *Binary) UnmarshalText(data []byte) error

Jump to

Keyboard shortcuts

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