infrastructure

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 19, 2026 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WrapDomainError

func WrapDomainError(err error) error

WrapDomainError 包装领域错误为基础设施错误

Types

type ErrCacheMiss

type ErrCacheMiss struct {
	Key string
}

ErrCacheMiss 缓存未命中错误

func (*ErrCacheMiss) Error

func (e *ErrCacheMiss) Error() string

type ErrFileNotFound

type ErrFileNotFound struct {
	FilePath string
	FileType string
}

ErrFileNotFound 文件不存在错误

func NewErrFileNotFound

func NewErrFileNotFound(filePath, fileType string) *ErrFileNotFound

NewErrFileNotFound 创建文件不存在错误

func (*ErrFileNotFound) Error

func (e *ErrFileNotFound) Error() string

type ErrOperationNotSupported

type ErrOperationNotSupported struct {
	DataSourceType string
	Operation      string
}

ErrOperationNotSupported 操作不支持错误

func NewErrOperationNotSupported

func NewErrOperationNotSupported(dataSourceType, operation string) *ErrOperationNotSupported

NewErrOperationNotSupported 创建操作不支持错误

func (*ErrOperationNotSupported) Error

func (e *ErrOperationNotSupported) Error() string

type ErrPoolExhausted

type ErrPoolExhausted struct {
	Message string
}

ErrPoolExhausted 连接池耗尽错误

func (*ErrPoolExhausted) Error

func (e *ErrPoolExhausted) Error() string

type ErrSQLNotSupported

type ErrSQLNotSupported struct {
	DataSourceType string
}

ErrSQLNotSupported SQL执行不支持错误

func NewErrSQLNotSupported

func NewErrSQLNotSupported(dataSourceType string) *ErrSQLNotSupported

NewErrSQLNotSupported 创建SQL不支持错误

func (*ErrSQLNotSupported) Error

func (e *ErrSQLNotSupported) Error() string

type ErrTypeConversion

type ErrTypeConversion struct {
	FieldName string
	FromType  string
	ToType    string
	Value     interface{}
}

ErrTypeConversion 类型转换错误

func (*ErrTypeConversion) Error

func (e *ErrTypeConversion) Error() string

Jump to

Keyboard shortcuts

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