deepcopy: add interface deepcopy funcs

- add DeepCopyObject() to runtime.Object interface
- add DeepCopyObject() via deepcopy-gen
- add DeepCopyObject() manually
- add DeepCopySelector() to selector interfaces
- add custom DeepCopy func for TableRow.Cells
This commit is contained in:
Dr. Stefan Schimanski
2017-07-06 10:59:05 +02:00
parent 774560085e
commit 39d95b9b06
135 changed files with 1063 additions and 12 deletions

View File

@@ -22,6 +22,7 @@ import (
)
// +genclient=true
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// Job represents the configuration of a single job.
type Job struct {
@@ -42,6 +43,8 @@ type Job struct {
Status JobStatus
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// JobList is a collection of jobs.
type JobList struct {
metav1.TypeMeta
@@ -54,6 +57,8 @@ type JobList struct {
Items []Job
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// JobTemplate describes a template for creating copies of a predefined pod.
type JobTemplate struct {
metav1.TypeMeta
@@ -188,6 +193,7 @@ type JobCondition struct {
}
// +genclient=true
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// CronJob represents the configuration of a single cron job.
type CronJob struct {
@@ -208,6 +214,8 @@ type CronJob struct {
Status CronJobStatus
}
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
// CronJobList is a collection of cron jobs.
type CronJobList struct {
metav1.TypeMeta