model

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Jul 12, 2024 License: MIT Imports: 1 Imported by: 6

Documentation

Index

Constants

View Source
const (
	ErrBase        string = "error"
	ErrUser        string = "user"
	ErrJwt         string = "jwt"
	ErrDb          string = "db"
	ErrRedis       string = "redis"
	ErrConnection  string = "connection"
	ErrToken       string = "token"
	ErrDecode      string = "decode"
	ErrChannelName string = "channelname"
)
View Source
const (
	ErrFailed         string = "failed"
	ErrNotFound       string = "notfound"
	ErrNotValid       string = "notvalid"
	ErrExpired        string = "expired"
	ErrorUnAuthorized string = "unauthorized"
)
View Source
const ErrSep string = "."

Variables

View Source
var (
	ChannelNone       string = "NONE"
	ChannelLogging    string = "LOGGING"
	ChannelCreateUser string = "CREATE_USER"
	ChannelDeleteUser string = "DELETE_USER"
	ChannelCreateDlr  string = "CREATE_DLR"
	ChannelDeleteDlr  string = "DELETE_DLR"
)
View Source
var (
	ErrorNone                error = nil
	ErrorRedisConnection           = errors.New(ErrBase + ErrSep + ErrRedis + ErrSep + ErrConnection + ErrSep + ErrFailed)
	ErrorDbConnection              = errors.New(ErrBase + ErrSep + ErrDb + ErrSep + ErrConnection + ErrSep + ErrFailed)
	ErrorUserNotFound              = errors.New(ErrBase + ErrSep + ErrUser + ErrSep + ErrNotFound)
	ErrorTokenExpired              = errors.New(ErrBase + ErrSep + ErrToken + ErrSep + ErrExpired)
	ErrorDecodeJwtFailed           = errors.New(ErrBase + ErrSep + ErrJwt + ErrSep + ErrDecode + ErrSep + ErrFailed)
	ErrorUserUnAuthorized          = errors.New(ErrBase + ErrSep + ErrUser + ErrSep + ErrorUnAuthorized)
	ErrorChannelNameNotValid       = errors.New(ErrBase + ErrSep + ErrChannelName + ErrSep + ErrNotValid)
)
View Source
var (
	ServiceNone    string = "NONE"
	ServiceUser    string = "USER"
	ServiceGraphQL string = "GRAPHQL"
)
View Source
var MESSAGES []string = []string{
	MessageNone,
}
View Source
var (
	MessageNone string = ""
)
View Source
var (
	SortedSetNone string = "NONE"
)

Functions

func GetErrors

func GetErrors() []error

func GetMessages

func GetMessages() []string

Types

type HeaderKey

type HeaderKey string
const (
	HeaderKeyContentType   HeaderKey = "Content-Type"
	HeaderKeyAppJson       HeaderKey = "application/json"
	HeaderKeyAuthorization HeaderKey = "Authorization"
)

type QueryKey

type QueryKey string
const (
	QueryKeyUid   QueryKey = "op_uid"
	QueryKeyUType QueryKey = "op_utype"
	QueryKeyToken QueryKey = "op_token"
)

Jump to

Keyboard shortcuts

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