test_vector_utils

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ElementSliceSliceToInterfaceSliceSlice

func ElementSliceSliceToInterfaceSliceSlice(x interface{}) [][]interface{}

func ElementSliceToInterfaceSlice

func ElementSliceToInterfaceSlice(x interface{}) []interface{}

func ElementToInterface

func ElementToInterface(x *fr.Element) interface{}

func HashFromDescription added in v0.9.1

func HashFromDescription(d HashDescription) (hash.Hash, error)

func NewMessageCounter

func NewMessageCounter(startState, step int) hash.Hash

func NewMessageCounterGenerator

func NewMessageCounterGenerator(startState, step int) func() hash.Hash

func PolynomialSliceEquals

func PolynomialSliceEquals(a []polynomial.Polynomial, b []polynomial.Polynomial) error

func SetElement

func SetElement(z *fr.Element, value interface{}) (*fr.Element, error)

func SliceEquals

func SliceEquals(a []fr.Element, b []fr.Element) error

func SliceSliceEquals

func SliceSliceEquals(a [][]fr.Element, b [][]fr.Element) error

func SliceToElementSlice

func SliceToElementSlice[T any](slice []T) ([]fr.Element, error)

func ToElement

func ToElement(i int64) *fr.Element

Types

type HashDescription added in v0.9.1

type HashDescription map[string]interface{}

type ListHash

type ListHash []fr.Element

func (*ListHash) BlockSize

func (h *ListHash) BlockSize() int

func (*ListHash) Reset

func (h *ListHash) Reset()

func (*ListHash) Size

func (h *ListHash) Size() int

func (*ListHash) Sum

func (h *ListHash) Sum(b []byte) []byte

func (*ListHash) Write

func (h *ListHash) Write(p []byte) (n int, err error)

type MessageCounter

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

func (*MessageCounter) BlockSize

func (m *MessageCounter) BlockSize() int

func (*MessageCounter) Reset

func (m *MessageCounter) Reset()

func (*MessageCounter) Size

func (m *MessageCounter) Size() int

func (*MessageCounter) Sum

func (m *MessageCounter) Sum(b []byte) []byte

func (*MessageCounter) Write

func (m *MessageCounter) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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