Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminAssignDoc ¶
type AdminAssignDoc struct {
Handler string `json:"handler"`
Type string `json:"type"`
Name string `json:"name"`
}
AdminAssignDoc assigns a document to a handler
type AdminAssignDocs ¶
type AdminAssignDocs struct {
Handler string `json:"handler"`
Docs []GetDocument `json:"docs"`
}
AdminAssignDocs assigns multiple documents to a handler
type AdminCmd ¶
type AdminCmd struct {
Cmd string `json:"cmd"`
RegisterHandler *RegisterHandler `json:"regHandler,omitempty"`
RegisterDocType *AdminRegisterDocType `json:"regDocType,omitempty"`
RequeueHandler *AdminRequeueHandler `json:"requeueHandler,omitempty"`
HandlerNewDoc *HandlerNewDoc `json:"handlerNewDoc,omitempty"`
RequeueDoc *AdminRequeueDoc `json:"requeueDoc,omitempty"`
AssignDoc *AdminAssignDoc `json:"assignDoc,omitempty"`
AssignDocs *AdminAssignDocs `json:"assignDocs,omitempty"`
}
AdminCmd is used for multiple different administrative commands
type AdminRegisterDocType ¶
type AdminRegisterDocType struct {
Type string `json:"type"`
}
AdminRegisterDocType is used to register a new document type
type AdminRequeueDoc ¶
AdminRequeueDoc is used to trigger all handlers that listen for a specific document
type AdminRequeueHandler ¶
type AdminRequeueHandler struct {
Handler string `json:"handler"`
}
AdminRequeueHandler is used to requeue a listeners of a handler
type Change ¶
type Change struct {
Handler string `json:"handler"`
Name string `json:"name"`
Documents []Document `json:"docs"`
}
Change contains documents which where affected by a change.
type Document ¶
type Document struct {
Type string `json:"type"`
Name string `json:"name"`
Version uint32 `json:"version"`
Document interface{} `json:"doc"`
}
Document contains a document content an meta data.
type GetDocument ¶
GetDocument is ues to get a specific document
type HandlerNewDoc ¶
type HandlerNewDoc struct {
Handler string `json:"handler"`
Type string `json:"type"`
Existing bool `json:"existing"`
}
HandlerNewDoc is used to define that a given handler should be called if a new document of a given type was created.
type ListenOnChange ¶
type ListenOnChange struct {
Handler string `json:"handler"`
Name string `json:"name"`
Documents []ListenOnChangeDocument `json:"docs"`
}
ListenOnChange is used to listen to changes.
type ListenOnChangeDocument ¶
type ListenOnChangeDocument struct {
Type string `json:"type"`
Name string `json:"name"`
NewDocument bool `json:"newDoc"`
Version uint32 `json:"version"`
Properties []string `json:"props"`
}
ListenOnChangeDocument is used to listen to a changes of specific document properties.
type PostDocument ¶
type PostDocument struct {
Type string `json:"type"`
Name string `json:"name"`
Document interface{} `json:"doc"`
}
PostDocument is used to post a document. This creates a new document or updates an existing one.
type RegisterHandler ¶
RegisterHandler regsisters a new Handler