integrity

package
v0.0.0-...-7112f6d Latest Latest
Warning

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

Go to latest
Published: Jun 16, 2021 License: GPL-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package integrity provides types to reduce API usage difficulty and avoid ambiguous args by type system

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BranchName

type BranchName string

BranchName is the name of a branch

type CRUD

type CRUD string

CRUD is any string which preserves any state of Create Retrieve Update or Delete

func (CRUD) ToHTTPVerb

func (crud CRUD) ToHTTPVerb() string

ToHTTPVerb retrieves the CRUD synonym by REST HTTP convention

func (CRUD) Validate

func (crud CRUD) Validate() error

Validate asserts if the string is any kind of CRUD actions

type ColumnName

type ColumnName string

ColumnName is the name of a column

type Id

type Id string

Id is a string in order to handle with every kind of id types (UUID/GUID/int)

func (Id) IsNil

func (id Id) IsNil() bool

IsNil verifies if the id is zero-valued

type OptionKey

type OptionKey string

An OptionKey is a key for any option (queryOption)

type SchemaName

type SchemaName string

SchemaName is the name of a Schema

type TableName

type TableName string

TableName is the name of a table

type Validator

type Validator func(interface{}) error

Validator is a func that returns an error if it doesn't pass the integrity checks for a given interface

type ValueType

type ValueType string

A ValueType is the string representation of a custom value type

Jump to

Keyboard shortcuts

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