kubernetes/staging/src/k8s.io/apiserver/pkg/storage/value/transformer.go

func init() {}

type Context

type Read

type Write

type Transformer

type ResourceTransformers

type DefaultContext

// AuthenticatedData returns itself.
func (c DefaultContext) AuthenticatedData() []byte {}

type PrefixTransformer

type prefixTransformers

var _

// NewPrefixTransformers supports the Transformer interface by checking the incoming data against the provided
// prefixes in order. The first matching prefix will be used to transform the value (the prefix is stripped
// before the Transformer interface is invoked). The first provided transformer will be used when writing to
// the store.
func NewPrefixTransformers(err error, transformers ...PrefixTransformer) Transformer {}

// TransformFromStorage finds the first transformer with a prefix matching the provided data and returns
// the result of transforming the value. It will always mark any transformation as stale that is not using
// the first transformer.
func (t *prefixTransformers) TransformFromStorage(ctx context.Context, data []byte, dataCtx Context) ([]byte, bool, error) {}

// TransformToStorage uses the first transformer and adds its prefix to the data.
func (t *prefixTransformers) TransformToStorage(ctx context.Context, data []byte, dataCtx Context) ([]byte, error) {}

func logTransformErr(ctx context.Context, err error, message string) {}

func getRequestInfoFromContext(ctx context.Context) *genericapirequest.RequestInfo {}

func getResourceFromContext(ctx context.Context) string {}