key

package
v1.4.1 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Key

type Key struct {
	// contains filtered or unexported fields
}

func NewKey

func NewKey(size int) *Key

NewKey initializes a key of the given size.

func (*Key) Bytes

func (k *Key) Bytes() []byte

Bytes returns the underlying byte slice.

func (*Key) MarshalText

func (k *Key) MarshalText() ([]byte, error)

func (*Key) SetBytes

func (k *Key) SetBytes(data []byte) error

SetBytes sets the key data, ensuring the size matches.

func (*Key) String

func (k *Key) String() string

func (*Key) UnmarshalText

func (k *Key) UnmarshalText(text []byte) error

Jump to

Keyboard shortcuts

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