errs

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 8, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Overview

error についてのサンプルが配置されているパッケージです。

Index

Constants

This section is empty.

Variables

View Source
var (
	SentinelError = errors.New("example: sentinel error check")
)

Functions

func NewRegister

func NewRegister() mappings.Register

func Sentinel

func Sentinel() error

Sentinel は、Goにおけるエラー処理イディオムの sentinel error check についてのサンプルです. REFERENCES::

func TypeAssertion

func TypeAssertion() error

TypeAssertion は、Goにおけるエラー処理イディオムの type assertion check についてのサンプルです. REFERENCES::

func WrapAndUnwrap

func WrapAndUnwrap() error

WrapAndUnwrap は、Goにおけるエラー処理にてエラーを内包するやり方についてのサンプルです。 REFERENCES::

Types

type TypeAssertionError

type TypeAssertionError struct{}

func (*TypeAssertionError) Error

func (t *TypeAssertionError) Error() string

type WrapError

type WrapError struct {
	InnerError error
}

func (*WrapError) Error

func (w *WrapError) Error() string

func (*WrapError) Unwrap

func (w *WrapError) Unwrap() error

Jump to

Keyboard shortcuts

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