asn1

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jul 17, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Marshal

func Marshal[S Serializer](values ...S) ([]byte, error)

func MarshalMath

func MarshalMath(values ...element) ([]byte, error)

func MarshalStd

func MarshalStd(a any) ([]byte, error)

func NewArray

func NewArray[S Serializer](values []S) (*array[S], error)

func NewArrayWithNew

func NewArrayWithNew[S Serializer](newFunction func() S) (*array[S], error)

func NewElementArray

func NewElementArray[E element](factors []E) (element, error)

func NewUnmarshaller

func NewUnmarshaller(raw []byte) (*unmarshaller, error)

func Unmarshal

func Unmarshal[S Serializer](data []byte, values ...S) error

func UnmarshalTo

func UnmarshalTo[S Serializer](data []byte, newFunction func() S) ([]S, error)

Types

type Element

type Element struct {
	CurveID int
	Raw     []byte
}

type Serializer

type Serializer interface {
	Serialize() ([]byte, error)
	Deserialize([]byte) error
}

type Values

type Values struct {
	Values [][]byte
}

Jump to

Keyboard shortcuts

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