mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 02:33:34 +00:00
rebase: bump k8s.io/api
Bumps the k8s-dependencies group with 1 update in the /api directory: [k8s.io/api](https://github.com/kubernetes/api). Updates `k8s.io/api` from 0.31.3 to 0.32.1 - [Commits](https://github.com/kubernetes/api/compare/v0.31.3...v0.32.1) --- updated-dependencies: - dependency-name: k8s.io/api dependency-type: direct:production update-type: version-update:semver-minor dependency-group: k8s-dependencies ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
8a66575825
commit
5aef21ea4e
18
api/vendor/k8s.io/apimachinery/pkg/runtime/helper.go
generated
vendored
18
api/vendor/k8s.io/apimachinery/pkg/runtime/helper.go
generated
vendored
@ -284,3 +284,21 @@ func (e *encoderWithAllocator) Encode(obj Object, w io.Writer) error {
|
||||
func (e *encoderWithAllocator) Identifier() Identifier {
|
||||
return e.encoder.Identifier()
|
||||
}
|
||||
|
||||
type nondeterministicEncoderToEncoderAdapter struct {
|
||||
NondeterministicEncoder
|
||||
}
|
||||
|
||||
func (e nondeterministicEncoderToEncoderAdapter) Encode(obj Object, w io.Writer) error {
|
||||
return e.EncodeNondeterministic(obj, w)
|
||||
}
|
||||
|
||||
// UseNondeterministicEncoding returns an Encoder that encodes objects using the provided Encoder's
|
||||
// EncodeNondeterministic method if it implements NondeterministicEncoder, otherwise it returns the
|
||||
// provided Encoder as-is.
|
||||
func UseNondeterministicEncoding(encoder Encoder) Encoder {
|
||||
if nondeterministic, ok := encoder.(NondeterministicEncoder); ok {
|
||||
return nondeterministicEncoderToEncoderAdapter{nondeterministic}
|
||||
}
|
||||
return encoder
|
||||
}
|
||||
|
Reference in New Issue
Block a user