errors

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 14, 2025 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrAPINotExist     = "APIGW.0101"
	ErrELBDataConflict = "ELB.8907"
)
View Source
const (
	ErrECSNotFound = "Ecs.0114"
)
View Source
const (
	ErrVPCNotFound = "VPC.0202"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseErrorHandler

type BaseErrorHandler struct{}

BaseErrorHandler provides common error handling methods.

func (BaseErrorHandler) ErrorCode

func (b BaseErrorHandler) ErrorCode(err error) string

func (BaseErrorHandler) StatusCode

func (b BaseErrorHandler) StatusCode(err error) int

type ECSErrorHandler

type ECSErrorHandler struct {
	BaseErrorHandler
}

ECSErrorHandler handles ECS-specific errors.

func (ECSErrorHandler) IsNotFound

func (e ECSErrorHandler) IsNotFound(err error) bool

type ELBErrorHandler

type ELBErrorHandler struct {
	BaseErrorHandler
}

ELBErrorHandler handles ELB-specific errors.

func (ELBErrorHandler) IsExists

func (e ELBErrorHandler) IsExists(err error) bool

func (ELBErrorHandler) IsNotFound

func (e ELBErrorHandler) IsNotFound(err error) bool

type ErrorHandler

type ErrorHandler interface {
	StatusCode(err error) int
	ErrorCode(err error) string
	IsNotFound(err error) bool
}

ErrorHandler defines the interface for handling errors.

type VPCErrorHandler

type VPCErrorHandler struct {
	BaseErrorHandler
}

VPCErrorHandler handles VPC-specific errors.

func (VPCErrorHandler) IsNotFound

func (v VPCErrorHandler) IsNotFound(err error) bool

Jump to

Keyboard shortcuts

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