convert

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package convert provides common functions for handling signal conversion.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InvalidTypeError

func InvalidTypeError() error

InvalidTypeError is returned when a field is not of the expected type or not found.

Types

type ConversionError

type ConversionError struct {
	// DecodedSignals is the list of signals that were successfully decoded.
	DecodedSignals []vss.Signal `json:"decodedSignals"`
	Errors         []error      `json:"errors"`
	TokenID        uint32       `json:"tokenId"`
	Source         string       `json:"source"`
}

ConversionError is an error that occurs during conversion.

func (ConversionError) Error

func (e ConversionError) Error() string

Error returns the error message.

func (ConversionError) Unwrap

func (e ConversionError) Unwrap() []error

Unwrap returns all errors that occurred during conversion.

type FieldNotFoundError

type FieldNotFoundError struct {
	Field  string
	Lookup string
}

FieldNotFoundError is an error for missing fields.

func (FieldNotFoundError) Error

func (e FieldNotFoundError) Error() string

Error returns the error message.

type VersionError

type VersionError struct {
	Version string
}

VersionError is an error for unsupported specversion.

func (VersionError) Error

func (e VersionError) Error() string

Error returns the error message.

Jump to

Keyboard shortcuts

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