errjson

package
v0.9.1 Latest Latest
Warning

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

Go to latest
Published: Nov 3, 2021 License: MIT Imports: 17 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Result

type Result struct {
	*corejson.Result
	ErrorWrapper *errorwrapper.Wrapper
}

func EmptyWithError

func EmptyWithError(err error) *Result

EmptyWithError wrapper will be empty error wrapper

func EmptyWithErrorPtrUsingErrorWrapper

func EmptyWithErrorPtrUsingErrorWrapper(
	wrapper *errorwrapper.Wrapper,
) *Result

EmptyWithErrorPtrUsingErrorWrapper wrapper nil will point to empty error wrapper

func EmptyWithoutErrorPtr

func EmptyWithoutErrorPtr() *Result

func Error

func Error(
	err error,
	errVariation errtype.Variation,
) *Result

func Marshal added in v0.7.3

func Marshal(anyObject interface{}) *Result

func New

func New(
	jsonBytes []byte,
	err error,
	typeName string,
) *Result

func NewBytes

func NewBytes(
	jsonBytes []byte,
	wrapper *errorwrapper.Wrapper,
) *Result

NewBytes wrapper nil will point to empty error wrapper

func NewBytesPtr

func NewBytesPtr(
	jsonBytes *[]byte,
	wrapper *errorwrapper.Wrapper,
) *Result

NewBytesPtr wrapper nil will point to empty error wrapper

func NewFromAny added in v0.8.7

func NewFromAny(
	anyItem interface{},
) *Result

func NewFromFile added in v0.3.0

func NewFromFile(filePath string) *Result

func NewFromFileLock added in v0.3.0

func NewFromFileLock(filePath string) *Result

func NewResultWithErrorWrapper added in v0.8.7

func NewResultWithErrorWrapper(
	jsonResult *corejson.Result,
	wrapper *errorwrapper.Wrapper,
) *Result

func NewUsingResult added in v0.8.7

func NewUsingResult(
	jsonResult *corejson.Result,
) *Result

func NewValue added in v0.8.7

func NewValue(
	jsonBytes []byte,
	typeName string,
) *Result

func (*Result) CompiledErrorWrapper added in v0.7.3

func (it *Result) CompiledErrorWrapper() *errorwrapper.Wrapper

func (*Result) HasAnyItem added in v0.7.3

func (it *Result) HasAnyItem() bool

func (*Result) HasError added in v0.7.0

func (it *Result) HasError() bool

func (*Result) HasIssuesOrEmpty added in v0.7.0

func (it *Result) HasIssuesOrEmpty() bool

func (*Result) HasSafeItems added in v0.7.0

func (it *Result) HasSafeItems() bool

HasSafeItems No errors and has items

func (*Result) IsAnyNull added in v0.8.7

func (it *Result) IsAnyNull() bool

func (*Result) IsEmpty added in v0.7.3

func (it *Result) IsEmpty() bool

func (*Result) IsEmptyError added in v0.7.0

func (it *Result) IsEmptyError() bool

func (*Result) IsEqual added in v0.8.7

func (it *Result) IsEqual(term string) bool

func (*Result) IsEqualIgnoreCase added in v0.8.7

func (it *Result) IsEqualIgnoreCase(term string) bool

func (*Result) IsEqualResult added in v0.8.9

func (it *Result) IsEqualResult(right *Result) bool

func (*Result) IsFailed added in v0.7.0

func (it *Result) IsFailed() bool

func (*Result) IsNull added in v0.7.0

func (it *Result) IsNull() bool

func (*Result) IsSuccess added in v0.7.0

func (it *Result) IsSuccess() bool

func (Result) JsonString added in v0.8.7

func (it Result) JsonString() string

func (*Result) Length added in v0.7.3

func (it *Result) Length() int

func (*Result) PrettyJsonBuffer added in v0.8.7

func (it *Result) PrettyJsonBuffer(prefix, indent string) (*bytes.Buffer, error)

func (Result) PrettyJsonString added in v0.8.7

func (it Result) PrettyJsonString() string

func (*Result) PrettyJsonStringWithErr added in v0.8.7

func (it *Result) PrettyJsonStringWithErr() string

func (*Result) SafeBytes added in v0.8.9

func (it *Result) SafeBytes() []byte

func (Result) SafeString added in v0.8.7

func (it Result) SafeString() string

func (*Result) SafeValues added in v0.8.7

func (it *Result) SafeValues() []byte

func (*Result) SafeValuesPtr added in v0.8.7

func (it *Result) SafeValuesPtr() *[]byte

func (*Result) SimpleStringOnce added in v0.8.7

func (it *Result) SimpleStringOnce(
	isInit bool,
) corestr.SimpleStringOnce

func (*Result) SplitLines added in v0.8.7

func (it *Result) SplitLines() []string

func (*Result) SplitLinesSimpleSlice added in v0.8.7

func (it *Result) SplitLinesSimpleSlice() *corestr.SimpleSlice

func (Result) String added in v0.7.0

func (it Result) String() string

func (*Result) UnmarshalErrorJson added in v0.8.7

func (it *Result) UnmarshalErrorJson(unmarshalToReferencePtr interface{}) *errorwrapper.Wrapper

func (*Result) UnmarshalJsonResultTo added in v0.8.7

func (it *Result) UnmarshalJsonResultTo(unmarshalToReferencePtr interface{}) *errorwrapper.Wrapper

func (*Result) ValidValue added in v0.8.7

func (it *Result) ValidValue() *corestr.ValidValue

type ResultsCollection added in v0.4.3

type ResultsCollection struct {
	*corejson.ResultsCollection
	ErrorCollection *errwrappers.Collection
}

func EmptyResultsCollection added in v0.4.3

func EmptyResultsCollection() *ResultsCollection

func NewResultsCollection added in v0.4.3

func NewResultsCollection(
	jsonCollection *corejson.ResultsCollection,
) *ResultsCollection

func NewResultsCollectionUsingAnyItems added in v0.8.7

func NewResultsCollectionUsingAnyItems(
	anyItems ...interface{},
) *ResultsCollection

func NewResultsCollectionUsingError added in v0.4.3

func NewResultsCollectionUsingError(
	err error,
) *ResultsCollection

func NewResultsCollectionUsingTypeError added in v0.4.3

func NewResultsCollectionUsingTypeError(
	errType errtype.Variation,
	err error,
) *ResultsCollection

func NewResultsCollectionUsingTypeMsg added in v0.4.3

func NewResultsCollectionUsingTypeMsg(
	errType errtype.Variation,
	msg string,
) *ResultsCollection

func (*ResultsCollection) Dispose added in v0.8.7

func (it *ResultsCollection) Dispose()

func (*ResultsCollection) HasError added in v0.8.7

func (it *ResultsCollection) HasError() bool

func (*ResultsCollection) IsAnyNull added in v0.8.7

func (it *ResultsCollection) IsAnyNull() bool

func (*ResultsCollection) IsEmpty added in v0.8.7

func (it *ResultsCollection) IsEmpty() bool

func (*ResultsCollection) Length added in v0.8.7

func (it *ResultsCollection) Length() int

Jump to

Keyboard shortcuts

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