divanSpecs

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const CRUD_CREATE = "create"
View Source
const CRUD_DELETE = "delete"
View Source
const CRUD_READ = "read"
View Source
const CRUD_UPDATE = "update"

Variables

This section is empty.

Functions

This section is empty.

Types

type CRUD

type CRUD struct {
	Routes             []string                      `json:"routes"`
	IDGenerator        func(data interface{}) string `json:"id_generator"`
	GetDocumentFrom    string                        `json:"get_document_from"`
	GetUpdateSpecsFrom string                        `json:"get_update_specs_from"`
	GetIDFrom          string                        `json:"get_id_from"`
	GetQueryFrom       string                        `json:"get_query_from"`
	SetQueryResultsIn  string                        `json:"set_query_results_in"`
	ReportFailuresIn   string                        `json:"report_failures_in"`
	AbortOnError       bool                          `json:"abort_on_error"`
}

func CRUDDefault

func CRUDDefault(modelName string) *CRUD

func (*CRUD) Default

func (c *CRUD) Default(modelName string) *CRUD

func (*CRUD) Equal

func (c *CRUD) Equal(d *CRUD) bool

func (*CRUD) Print

func (c *CRUD) Print() string

type Update

type Update struct {
	Remove    []string               `json:"remove"`
	Upsert    map[string]interface{} `json:"upsert"`
	Append    map[string]interface{} `json:"append"`
	Reference interface{}            `json:"reference"`
}

func (*Update) Normalize

func (u *Update) Normalize()

Jump to

Keyboard shortcuts

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