dal

package
v0.333.2 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2024 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package dal provides common types and functions for domain-specific DALs.

In particular, common error types and error handling function for all domain-specific DALs, e.g. controller DAL and configuration DAL, which all connect to the same underlying DB and maintain the same interface guarantees

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrConflict is returned by select methods in the DAL when a resource already exists.
	//
	// Its use will be documented in the corresponding methods.
	ErrConflict = errors.New("conflict")
	// ErrNotFound is returned by select methods in the DAL when no results are found.
	ErrNotFound = errors.New("not found")
	// ErrConstraint is returned by select methods in the DAL when a constraint is violated.
	ErrConstraint = errors.New("constraint violation")
)

Functions

func IsNotFound

func IsNotFound(err error) bool

func TranslatePGError

func TranslatePGError(err error) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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