Documentation ¶
Index ¶
- func AddJointModelDispatcher(prefix string, app *appsrv.Application, manager IJointModelDispatchHandler)
- func AddModelDispatcher(prefix string, app *appsrv.Application, manager IModelDispatchHandler)
- type IJointModelDispatchHandler
- type IMiddlewareFilter
- type IModelDispatchHandler
- type SResourceContext
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddJointModelDispatcher ¶
func AddJointModelDispatcher(prefix string, app *appsrv.Application, manager IJointModelDispatchHandler)
func AddModelDispatcher ¶
func AddModelDispatcher(prefix string, app *appsrv.Application, manager IModelDispatchHandler)
Types ¶
type IJointModelDispatchHandler ¶
type IJointModelDispatchHandler interface { IMiddlewareFilter Keyword() string KeywordPlural() string MasterKeywordPlural() string SlaveKeywordPlural() string List(ctx context.Context, query jsonutils.JSONObject, ctxIds []SResourceContext) (*modulebase.ListResult, error) ListMasterDescendent(ctx context.Context, idStr string, query jsonutils.JSONObject) (*modulebase.ListResult, error) ListSlaveDescendent(ctx context.Context, idStr string, query jsonutils.JSONObject) (*modulebase.ListResult, error) Get(ctx context.Context, id1 string, id2 string, query jsonutils.JSONObject) (jsonutils.JSONObject, error) Attach(ctx context.Context, id1 string, id2 string, query jsonutils.JSONObject, body jsonutils.JSONObject) (jsonutils.JSONObject, error) Update(ctx context.Context, id1 string, id2 string, query jsonutils.JSONObject, body jsonutils.JSONObject) (jsonutils.JSONObject, error) Detach(ctx context.Context, id1 string, id2 string, query jsonutils.JSONObject, body jsonutils.JSONObject) (jsonutils.JSONObject, error) }
type IMiddlewareFilter ¶
type IMiddlewareFilter interface {
Filter(appsrv.FilterHandler) appsrv.FilterHandler
}
type IModelDispatchHandler ¶
type IModelDispatchHandler interface { IMiddlewareFilter Keyword() string KeywordPlural() string ContextKeywordPlurals() [][]string List(ctx context.Context, query jsonutils.JSONObject, ctxIds []SResourceContext) (*modulebase.ListResult, error) Get(ctx context.Context, idstr string, query jsonutils.JSONObject, isHead bool) (jsonutils.JSONObject, error) GetSpecific(ctx context.Context, idstr string, spec string, query jsonutils.JSONObject) (jsonutils.JSONObject, error) Create(ctx context.Context, query jsonutils.JSONObject, data jsonutils.JSONObject, ctxIds []SResourceContext) (jsonutils.JSONObject, error) BatchCreate(ctx context.Context, query jsonutils.JSONObject, data jsonutils.JSONObject, count int, ctxIds []SResourceContext) ([]modulebase.SubmitResult, error) PerformClassAction(ctx context.Context, action string, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) PerformAction(ctx context.Context, idstr string, action string, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) // UpdateClass(ctx context.Context, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) Update(ctx context.Context, idstr string, query jsonutils.JSONObject, data jsonutils.JSONObject, ctxIds []SResourceContext) (jsonutils.JSONObject, error) UpdateSpec(ctx context.Context, idstr string, spec string, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) // DeleteClass(ctx context.Context, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) Delete(ctx context.Context, idstr string, query jsonutils.JSONObject, data jsonutils.JSONObject, ctxIds []SResourceContext) (jsonutils.JSONObject, error) DeleteSpec(ctx context.Context, idstr string, spec string, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error) CustomizeHandlerInfo(info *appsrv.SHandlerInfo) FetchCreateHeaderData(ctx context.Context, header http.Header) (jsonutils.JSONObject, error) FetchUpdateHeaderData(ctx context.Context, header http.Header) (jsonutils.JSONObject, error) }
type SResourceContext ¶
Click to show internal directories.
Click to hide internal directories.