commonutils

package
v0.14.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2025 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DecodeJSONWithHresult

func DecodeJSONWithHresult(r io.Reader, v interface{}) error

DecodeJSONWithHresult decodes the JSON from the given reader into the given interface, and wraps any error returned in an HRESULT error.

func UnmarshalJSONWithHresult

func UnmarshalJSONWithHresult(data []byte, v interface{}) error

UnmarshalJSONWithHresult unmarshals the given data into the given interface, and wraps any error returned in an HRESULT error.

Types

type ErrorRecord

type ErrorRecord struct {
	Result       int32 // HResult
	Message      string
	StackTrace   string `json:",omitempty"`
	ModuleName   string
	FileName     string
	Line         uint32
	FunctionName string `json:",omitempty"`
}

func SetErrorForResponseBaseUtil

func SetErrorForResponseBaseUtil(errForResponse error, moduleName string) (hresult gcserr.Hresult, errorMessage string, newRecord ErrorRecord)

Jump to

Keyboard shortcuts

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