Introduce ObjectConvertor for conversion to known API versions
Will allow clients to transform internal objects to a version suitable for external output.
This commit is contained in:
@@ -33,6 +33,11 @@ type Codec interface {
|
||||
Encoder
|
||||
}
|
||||
|
||||
// ObjectConvertor converts an object to a different version.
|
||||
type ObjectConvertor interface {
|
||||
ConvertToVersion(in Object, outVersion string) (out Object, err error)
|
||||
}
|
||||
|
||||
// ObjectTyper contains methods for extracting the APIVersion and Kind
|
||||
// of objects.
|
||||
type ObjectTyper interface {
|
||||
|
Reference in New Issue
Block a user