|
| 1 | +/* |
| 2 | +Copyright 2021 The Kubernetes Authors. |
| 3 | +
|
| 4 | +Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | +you may not use this file except in compliance with the License. |
| 6 | +You may obtain a copy of the License at |
| 7 | +
|
| 8 | + http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | +
|
| 10 | +Unless required by applicable law or agreed to in writing, software |
| 11 | +distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | +See the License for the specific language governing permissions and |
| 14 | +limitations under the License. |
| 15 | +*/ |
| 16 | + |
| 17 | +package api |
| 18 | + |
| 19 | +type Proposals []*Proposal |
| 20 | + |
| 21 | +func (p *Proposals) AddProposal(proposal *Proposal) { |
| 22 | + *p = append(*p, proposal) |
| 23 | +} |
| 24 | + |
| 25 | +type Proposal struct { |
| 26 | + ID string `json:"id"` |
| 27 | + PRNumber string `json:"prNumber,omitempty"` |
| 28 | + Name string `json:"name,omitempty"` |
| 29 | + |
| 30 | + Title string `json:"title" yaml:"title"` |
| 31 | + Number string `json:"kep-number" yaml:"kep-number"` |
| 32 | + Authors []string `json:"authors" yaml:",flow"` |
| 33 | + OwningSIG string `json:"owningSig" yaml:"owning-sig"` |
| 34 | + ParticipatingSIGs []string `json:"participatingSigs" yaml:"participating-sigs,flow,omitempty"` |
| 35 | + Reviewers []string `json:"reviewers" yaml:",flow"` |
| 36 | + Approvers []string `json:"approvers" yaml:",flow"` |
| 37 | + PRRApprovers []string `json:"prrApprovers" yaml:"prr-approvers,flow"` |
| 38 | + Editor string `json:"editor" yaml:"editor,omitempty"` |
| 39 | + CreationDate string `json:"creationDate" yaml:"creation-date"` |
| 40 | + LastUpdated string `json:"lastUpdated" yaml:"last-updated"` |
| 41 | + Status string `json:"status" yaml:"status"` |
| 42 | + SeeAlso []string `json:"seeAlso" yaml:"see-also,omitempty"` |
| 43 | + Replaces []string `json:"replaces" yaml:"replaces,omitempty"` |
| 44 | + SupersededBy []string `json:"supersededBy" yaml:"superseded-by,omitempty"` |
| 45 | + |
| 46 | + Stage string `json:"stage" yaml:"stage"` |
| 47 | + LatestMilestone string `json:"latestMilestone" yaml:"latest-milestone"` |
| 48 | + Milestone Milestone `json:"milestone" yaml:"milestone"` |
| 49 | + |
| 50 | + FeatureGates []FeatureGate `json:"featureGates" yaml:"feature-gates"` |
| 51 | + DisableSupported bool `json:"disableSupported" yaml:"disable-supported"` |
| 52 | + Metrics []string `json:"metrics" yaml:"metrics"` |
| 53 | + |
| 54 | + Filename string `json:"-" yaml:"-"` |
| 55 | + Error error `json:"-" yaml:"-"` |
| 56 | + Contents string `json:"markdown" yaml:"-"` |
| 57 | +} |
| 58 | + |
| 59 | +type Milestone struct { |
| 60 | + Alpha string `json:"alpha" yaml:"alpha"` |
| 61 | + Beta string `json:"beta" yaml:"beta"` |
| 62 | + Stable string `json:"stable" yaml:"stable"` |
| 63 | +} |
| 64 | + |
| 65 | +type FeatureGate struct { |
| 66 | + Name string `json:"name" yaml:"name"` |
| 67 | + Components []string `json:"components" yaml:"components"` |
| 68 | +} |
0 commit comments