type
BoundTypedGlobal
type BoundTypedGlobal[Document, Update any] struct {
definition TypedGlobal[Document, Update]
local *LocalAPI
}Typed Find, Update, Publish, Unpublish, Restore, and RestoreAsDraft methods.
Source core/typed_global.go:29
Find(ctx, actor)(Document, error)- Read and JSON-decode the singleton into the generated model.
Update(ctx, input, expectedRevision, actor)(Document, error)- Create or update the typed singleton.
Publish(ctx, expectedRevision, actor)(Document, error)- Publish the current singleton revision.
Unpublish(ctx, expectedRevision, actor)(Document, error)- Return the singleton to draft.
Restore(ctx, revision, expectedRevision, actor)(Document, error)- Restore a retained revision as published content.
RestoreAsDraft(ctx, revision, expectedRevision, actor)(Document, error)- Restore a retained revision as a draft.
Generated wrappers keep singleton methods discoverable without changing LocalAPI semantics or authorization.
Methods
BoundTypedGlobal.Find()Public method BoundTypedGlobal.Find from github.com/riducms/ridu/core.
BoundTypedGlobal.Publish()Public method BoundTypedGlobal.Publish from github.com/riducms/ridu/core.
BoundTypedGlobal.Restore()Public method BoundTypedGlobal.Restore from github.com/riducms/ridu/core.
BoundTypedGlobal.RestoreAsDraft()Public method BoundTypedGlobal.RestoreAsDraft from github.com/riducms/ridu/core.
BoundTypedGlobal.Unpublish()Public method BoundTypedGlobal.Unpublish from github.com/riducms/ridu/core.
BoundTypedGlobal.Update()Public method BoundTypedGlobal.Update from github.com/riducms/ridu/core.