method

LocalAPI.CopyLocale

CopyLocale preserves the exact authenticated collection identity for both the source read and destination mutation lifecycle.

Arguments

ArgumentTypeDescription
ctxcontext.ContextThe ctx value.
collectionstringThe collection value.
idstringThe id value.
sourceschema.LocaleCodeThe source value.
targetschema.LocaleCodeThe target value.
optionsMutationOptionsThe options value.

Returns

The declared result.

(store.Document, error)

Full signature

func (local *LocalAPI) CopyLocale( ctx context.Context, collection, id string, source, target schema.LocaleCode, options MutationOptions, ) (store.Document, error)

Source core/local.go:561

Related types

  • LocalAPI

    In-process content operations that share the REST authorization and lifecycle pipeline.

  • LocaleCode

    A validated locale identity used by operations, manifests, and storage.

  • MutationOptions

    Authorization, optimistic concurrency, response population, create status, and locale controls for one write.

  • Document

    A stored document with status and version metadata.