mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 11:21:47 +00:00
Generated code for ResourceQuota API change
This commit is contained in:
parent
55e3824272
commit
d02c8dcd2e
@ -17515,9 +17515,20 @@
|
|||||||
"hard": {
|
"hard": {
|
||||||
"type": "any",
|
"type": "any",
|
||||||
"description": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota"
|
"description": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota"
|
||||||
|
},
|
||||||
|
"scopes": {
|
||||||
|
"type": "array",
|
||||||
|
"items": {
|
||||||
|
"$ref": "v1.ResourceQuotaScope"
|
||||||
|
},
|
||||||
|
"description": "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects."
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"v1.ResourceQuotaScope": {
|
||||||
|
"id": "v1.ResourceQuotaScope",
|
||||||
|
"properties": {}
|
||||||
|
},
|
||||||
"v1.ResourceQuotaStatus": {
|
"v1.ResourceQuotaStatus": {
|
||||||
"id": "v1.ResourceQuotaStatus",
|
"id": "v1.ResourceQuotaStatus",
|
||||||
"description": "ResourceQuotaStatus defines the enforced hard limits and observed use.",
|
"description": "ResourceQuotaStatus defines the enforced hard limits and observed use.",
|
||||||
|
@ -5591,7 +5591,7 @@ Populated by the system when a graceful deletion is requested. Read-only. More i
|
|||||||
</div>
|
</div>
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
<div id="footer-text">
|
<div id="footer-text">
|
||||||
Last updated 2016-02-26 21:38:01 UTC
|
Last updated 2016-02-27 01:28:36 UTC
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
@ -1064,6 +1064,13 @@ Examples:<br>
|
|||||||
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="#_any">any</a></p></td>
|
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="#_any">any</a></p></td>
|
||||||
<td class="tableblock halign-left valign-top"></td>
|
<td class="tableblock halign-left valign-top"></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td class="tableblock halign-left valign-top"><p class="tableblock">scopes</p></td>
|
||||||
|
<td class="tableblock halign-left valign-top"><p class="tableblock">A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.</p></td>
|
||||||
|
<td class="tableblock halign-left valign-top"><p class="tableblock">false</p></td>
|
||||||
|
<td class="tableblock halign-left valign-top"><p class="tableblock"><a href="#_v1_resourcequotascope">v1.ResourceQuotaScope</a> array</p></td>
|
||||||
|
<td class="tableblock halign-left valign-top"></td>
|
||||||
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
@ -6188,6 +6195,10 @@ The resulting set of endpoints can be viewed as:<br>
|
|||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="sect2">
|
||||||
|
<h3 id="_v1_resourcequotascope">v1.ResourceQuotaScope</h3>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="sect2">
|
<div class="sect2">
|
||||||
<h3 id="_v1_replicationcontrollerlist">v1.ReplicationControllerList</h3>
|
<h3 id="_v1_replicationcontrollerlist">v1.ReplicationControllerList</h3>
|
||||||
@ -7477,7 +7488,7 @@ The resulting set of endpoints can be viewed as:<br>
|
|||||||
</div>
|
</div>
|
||||||
<div id="footer">
|
<div id="footer">
|
||||||
<div id="footer-text">
|
<div id="footer-text">
|
||||||
Last updated 2016-02-26 21:37:52 UTC
|
Last updated 2016-02-27 01:28:28 UTC
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</body>
|
</body>
|
||||||
|
@ -2455,6 +2455,15 @@ func DeepCopy_api_ResourceQuotaSpec(in ResourceQuotaSpec, out *ResourceQuotaSpec
|
|||||||
} else {
|
} else {
|
||||||
out.Hard = nil
|
out.Hard = nil
|
||||||
}
|
}
|
||||||
|
if in.Scopes != nil {
|
||||||
|
in, out := in.Scopes, &out.Scopes
|
||||||
|
*out = make([]ResourceQuotaScope, len(in))
|
||||||
|
for i := range in {
|
||||||
|
(*out)[i] = in[i]
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.Scopes = nil
|
||||||
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -44187,6 +44187,32 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
|||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
yym1 := z.EncBinary()
|
||||||
|
_ = yym1
|
||||||
|
if false {
|
||||||
|
} else if z.HasExtensions() && z.EncExt(x) {
|
||||||
|
} else {
|
||||||
|
r.EncodeString(codecSelferC_UTF81234, string(x))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ResourceQuotaScope) CodecDecodeSelf(d *codec1978.Decoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
yym1 := z.DecBinary()
|
||||||
|
_ = yym1
|
||||||
|
if false {
|
||||||
|
} else if z.HasExtensions() && z.DecExt(x) {
|
||||||
|
} else {
|
||||||
|
*((*string)(x)) = r.DecodeString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperEncoder(e)
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
@ -44201,13 +44227,14 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
|||||||
} else {
|
} else {
|
||||||
yysep2 := !z.EncBinary()
|
yysep2 := !z.EncBinary()
|
||||||
yy2arr2 := z.EncBasicHandle().StructToArray
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
||||||
var yyq2 [1]bool
|
var yyq2 [2]bool
|
||||||
_, _, _ = yysep2, yyq2, yy2arr2
|
_, _, _ = yysep2, yyq2, yy2arr2
|
||||||
const yyr2 bool = false
|
const yyr2 bool = false
|
||||||
yyq2[0] = len(x.Hard) != 0
|
yyq2[0] = len(x.Hard) != 0
|
||||||
|
yyq2[1] = len(x.Scopes) != 0
|
||||||
var yynn2 int
|
var yynn2 int
|
||||||
if yyr2 || yy2arr2 {
|
if yyr2 || yy2arr2 {
|
||||||
r.EncodeArrayStart(1)
|
r.EncodeArrayStart(2)
|
||||||
} else {
|
} else {
|
||||||
yynn2 = 0
|
yynn2 = 0
|
||||||
for _, b := range yyq2 {
|
for _, b := range yyq2 {
|
||||||
@ -44241,6 +44268,39 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if yyr2 || yy2arr2 {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
if yyq2[1] {
|
||||||
|
if x.Scopes == nil {
|
||||||
|
r.EncodeNil()
|
||||||
|
} else {
|
||||||
|
yym7 := z.EncBinary()
|
||||||
|
_ = yym7
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
r.EncodeNil()
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if yyq2[1] {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerMapKey1234)
|
||||||
|
r.EncodeString(codecSelferC_UTF81234, string("scopes"))
|
||||||
|
z.EncSendContainerState(codecSelfer_containerMapValue1234)
|
||||||
|
if x.Scopes == nil {
|
||||||
|
r.EncodeNil()
|
||||||
|
} else {
|
||||||
|
yym8 := z.EncBinary()
|
||||||
|
_ = yym8
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if yyr2 || yy2arr2 {
|
if yyr2 || yy2arr2 {
|
||||||
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
} else {
|
} else {
|
||||||
@ -44309,6 +44369,18 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder)
|
|||||||
yyv4 := &x.Hard
|
yyv4 := &x.Hard
|
||||||
yyv4.CodecDecodeSelf(d)
|
yyv4.CodecDecodeSelf(d)
|
||||||
}
|
}
|
||||||
|
case "scopes":
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
x.Scopes = nil
|
||||||
|
} else {
|
||||||
|
yyv5 := &x.Scopes
|
||||||
|
yym6 := z.DecBinary()
|
||||||
|
_ = yym6
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv5), d)
|
||||||
|
}
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
z.DecStructFieldNotFound(-1, yys3)
|
z.DecStructFieldNotFound(-1, yys3)
|
||||||
} // end switch yys3
|
} // end switch yys3
|
||||||
@ -44320,16 +44392,16 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder
|
|||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperDecoder(d)
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
_, _, _ = h, z, r
|
_, _, _ = h, z, r
|
||||||
var yyj5 int
|
var yyj7 int
|
||||||
var yyb5 bool
|
var yyb7 bool
|
||||||
var yyhl5 bool = l >= 0
|
var yyhl7 bool = l >= 0
|
||||||
yyj5++
|
yyj7++
|
||||||
if yyhl5 {
|
if yyhl7 {
|
||||||
yyb5 = yyj5 > l
|
yyb7 = yyj7 > l
|
||||||
} else {
|
} else {
|
||||||
yyb5 = r.CheckBreak()
|
yyb7 = r.CheckBreak()
|
||||||
}
|
}
|
||||||
if yyb5 {
|
if yyb7 {
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -44337,21 +44409,43 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder
|
|||||||
if r.TryDecodeAsNil() {
|
if r.TryDecodeAsNil() {
|
||||||
x.Hard = nil
|
x.Hard = nil
|
||||||
} else {
|
} else {
|
||||||
yyv6 := &x.Hard
|
yyv8 := &x.Hard
|
||||||
yyv6.CodecDecodeSelf(d)
|
yyv8.CodecDecodeSelf(d)
|
||||||
|
}
|
||||||
|
yyj7++
|
||||||
|
if yyhl7 {
|
||||||
|
yyb7 = yyj7 > l
|
||||||
|
} else {
|
||||||
|
yyb7 = r.CheckBreak()
|
||||||
|
}
|
||||||
|
if yyb7 {
|
||||||
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
x.Scopes = nil
|
||||||
|
} else {
|
||||||
|
yyv9 := &x.Scopes
|
||||||
|
yym10 := z.DecBinary()
|
||||||
|
_ = yym10
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv9), d)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
for {
|
for {
|
||||||
yyj5++
|
yyj7++
|
||||||
if yyhl5 {
|
if yyhl7 {
|
||||||
yyb5 = yyj5 > l
|
yyb7 = yyj7 > l
|
||||||
} else {
|
} else {
|
||||||
yyb5 = r.CheckBreak()
|
yyb7 = r.CheckBreak()
|
||||||
}
|
}
|
||||||
if yyb5 {
|
if yyb7 {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
z.DecStructFieldNotFound(yyj5-1, "")
|
z.DecStructFieldNotFound(yyj7-1, "")
|
||||||
}
|
}
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
}
|
}
|
||||||
@ -53768,6 +53862,116 @@ func (x codecSelfer1234) decSliceLimitRange(v *[]LimitRange, d *codec1978.Decode
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x codecSelfer1234) encSliceResourceQuotaScope(v []ResourceQuotaScope, e *codec1978.Encoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
r.EncodeArrayStart(len(v))
|
||||||
|
for _, yyv1 := range v {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
yyv1.CodecEncodeSelf(e)
|
||||||
|
}
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x codecSelfer1234) decSliceResourceQuotaScope(v *[]ResourceQuotaScope, d *codec1978.Decoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
|
||||||
|
yyv1 := *v
|
||||||
|
yyh1, yyl1 := z.DecSliceHelperStart()
|
||||||
|
var yyc1 bool
|
||||||
|
_ = yyc1
|
||||||
|
if yyl1 == 0 {
|
||||||
|
if yyv1 == nil {
|
||||||
|
yyv1 = []ResourceQuotaScope{}
|
||||||
|
yyc1 = true
|
||||||
|
} else if len(yyv1) != 0 {
|
||||||
|
yyv1 = yyv1[:0]
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
} else if yyl1 > 0 {
|
||||||
|
var yyrr1, yyrl1 int
|
||||||
|
var yyrt1 bool
|
||||||
|
_, _ = yyrl1, yyrt1
|
||||||
|
yyrr1 = yyl1 // len(yyv1)
|
||||||
|
if yyl1 > cap(yyv1) {
|
||||||
|
|
||||||
|
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
|
||||||
|
if yyrt1 {
|
||||||
|
if yyrl1 <= cap(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyrl1]
|
||||||
|
} else {
|
||||||
|
yyv1 = make([]ResourceQuotaScope, yyrl1)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
yyv1 = make([]ResourceQuotaScope, yyrl1)
|
||||||
|
}
|
||||||
|
yyc1 = true
|
||||||
|
yyrr1 = len(yyv1)
|
||||||
|
} else if yyl1 != len(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyl1]
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
yyj1 := 0
|
||||||
|
for ; yyj1 < yyrr1; yyj1++ {
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if yyrt1 {
|
||||||
|
for ; yyj1 < yyl1; yyj1++ {
|
||||||
|
yyv1 = append(yyv1, "")
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
yyj1 := 0
|
||||||
|
for ; !r.CheckBreak(); yyj1++ {
|
||||||
|
|
||||||
|
if yyj1 >= len(yyv1) {
|
||||||
|
yyv1 = append(yyv1, "") // var yyz1 ResourceQuotaScope
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if yyj1 < len(yyv1) {
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
z.DecSwallow()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if yyj1 < len(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyj1]
|
||||||
|
yyc1 = true
|
||||||
|
} else if yyj1 == 0 && yyv1 == nil {
|
||||||
|
yyv1 = []ResourceQuotaScope{}
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
yyh1.End()
|
||||||
|
if yyc1 {
|
||||||
|
*v = yyv1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.Encoder) {
|
func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.Encoder) {
|
||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperEncoder(e)
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
@ -53807,7 +54011,7 @@ func (x codecSelfer1234) decSliceResourceQuota(v *[]ResourceQuota, d *codec1978.
|
|||||||
|
|
||||||
yyrg1 := len(yyv1) > 0
|
yyrg1 := len(yyv1) > 0
|
||||||
yyv21 := yyv1
|
yyv21 := yyv1
|
||||||
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 216)
|
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 240)
|
||||||
if yyrt1 {
|
if yyrt1 {
|
||||||
if yyrl1 <= cap(yyv1) {
|
if yyrl1 <= cap(yyv1) {
|
||||||
yyv1 = yyv1[:yyrl1]
|
yyv1 = yyv1[:yyrl1]
|
||||||
|
@ -2666,6 +2666,14 @@ func autoConvert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in *api.ResourceQ
|
|||||||
} else {
|
} else {
|
||||||
out.Hard = nil
|
out.Hard = nil
|
||||||
}
|
}
|
||||||
|
if in.Scopes != nil {
|
||||||
|
out.Scopes = make([]ResourceQuotaScope, len(in.Scopes))
|
||||||
|
for i := range in.Scopes {
|
||||||
|
out.Scopes[i] = ResourceQuotaScope(in.Scopes[i])
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.Scopes = nil
|
||||||
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -5887,6 +5895,14 @@ func autoConvert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in *ResourceQuota
|
|||||||
if err := s.Convert(&in.Hard, &out.Hard, 0); err != nil {
|
if err := s.Convert(&in.Hard, &out.Hard, 0); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
if in.Scopes != nil {
|
||||||
|
out.Scopes = make([]api.ResourceQuotaScope, len(in.Scopes))
|
||||||
|
for i := range in.Scopes {
|
||||||
|
out.Scopes[i] = api.ResourceQuotaScope(in.Scopes[i])
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.Scopes = nil
|
||||||
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2084,6 +2084,14 @@ func deepCopy_v1_ResourceQuotaSpec(in ResourceQuotaSpec, out *ResourceQuotaSpec,
|
|||||||
} else {
|
} else {
|
||||||
out.Hard = nil
|
out.Hard = nil
|
||||||
}
|
}
|
||||||
|
if in.Scopes != nil {
|
||||||
|
out.Scopes = make([]ResourceQuotaScope, len(in.Scopes))
|
||||||
|
for i := range in.Scopes {
|
||||||
|
out.Scopes[i] = in.Scopes[i]
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
out.Scopes = nil
|
||||||
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -43999,6 +43999,32 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) {
|
|||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
yym1 := z.EncBinary()
|
||||||
|
_ = yym1
|
||||||
|
if false {
|
||||||
|
} else if z.HasExtensions() && z.EncExt(x) {
|
||||||
|
} else {
|
||||||
|
r.EncodeString(codecSelferC_UTF81234, string(x))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x *ResourceQuotaScope) CodecDecodeSelf(d *codec1978.Decoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
yym1 := z.DecBinary()
|
||||||
|
_ = yym1
|
||||||
|
if false {
|
||||||
|
} else if z.HasExtensions() && z.DecExt(x) {
|
||||||
|
} else {
|
||||||
|
*((*string)(x)) = r.DecodeString()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperEncoder(e)
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
@ -44013,13 +44039,14 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
|||||||
} else {
|
} else {
|
||||||
yysep2 := !z.EncBinary()
|
yysep2 := !z.EncBinary()
|
||||||
yy2arr2 := z.EncBasicHandle().StructToArray
|
yy2arr2 := z.EncBasicHandle().StructToArray
|
||||||
var yyq2 [1]bool
|
var yyq2 [2]bool
|
||||||
_, _, _ = yysep2, yyq2, yy2arr2
|
_, _, _ = yysep2, yyq2, yy2arr2
|
||||||
const yyr2 bool = false
|
const yyr2 bool = false
|
||||||
yyq2[0] = len(x.Hard) != 0
|
yyq2[0] = len(x.Hard) != 0
|
||||||
|
yyq2[1] = len(x.Scopes) != 0
|
||||||
var yynn2 int
|
var yynn2 int
|
||||||
if yyr2 || yy2arr2 {
|
if yyr2 || yy2arr2 {
|
||||||
r.EncodeArrayStart(1)
|
r.EncodeArrayStart(2)
|
||||||
} else {
|
} else {
|
||||||
yynn2 = 0
|
yynn2 = 0
|
||||||
for _, b := range yyq2 {
|
for _, b := range yyq2 {
|
||||||
@ -44053,6 +44080,39 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if yyr2 || yy2arr2 {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
if yyq2[1] {
|
||||||
|
if x.Scopes == nil {
|
||||||
|
r.EncodeNil()
|
||||||
|
} else {
|
||||||
|
yym7 := z.EncBinary()
|
||||||
|
_ = yym7
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
r.EncodeNil()
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if yyq2[1] {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerMapKey1234)
|
||||||
|
r.EncodeString(codecSelferC_UTF81234, string("scopes"))
|
||||||
|
z.EncSendContainerState(codecSelfer_containerMapValue1234)
|
||||||
|
if x.Scopes == nil {
|
||||||
|
r.EncodeNil()
|
||||||
|
} else {
|
||||||
|
yym8 := z.EncBinary()
|
||||||
|
_ = yym8
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
if yyr2 || yy2arr2 {
|
if yyr2 || yy2arr2 {
|
||||||
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
} else {
|
} else {
|
||||||
@ -44121,6 +44181,18 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder)
|
|||||||
yyv4 := &x.Hard
|
yyv4 := &x.Hard
|
||||||
yyv4.CodecDecodeSelf(d)
|
yyv4.CodecDecodeSelf(d)
|
||||||
}
|
}
|
||||||
|
case "scopes":
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
x.Scopes = nil
|
||||||
|
} else {
|
||||||
|
yyv5 := &x.Scopes
|
||||||
|
yym6 := z.DecBinary()
|
||||||
|
_ = yym6
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv5), d)
|
||||||
|
}
|
||||||
|
}
|
||||||
default:
|
default:
|
||||||
z.DecStructFieldNotFound(-1, yys3)
|
z.DecStructFieldNotFound(-1, yys3)
|
||||||
} // end switch yys3
|
} // end switch yys3
|
||||||
@ -44132,16 +44204,16 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder
|
|||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperDecoder(d)
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
_, _, _ = h, z, r
|
_, _, _ = h, z, r
|
||||||
var yyj5 int
|
var yyj7 int
|
||||||
var yyb5 bool
|
var yyb7 bool
|
||||||
var yyhl5 bool = l >= 0
|
var yyhl7 bool = l >= 0
|
||||||
yyj5++
|
yyj7++
|
||||||
if yyhl5 {
|
if yyhl7 {
|
||||||
yyb5 = yyj5 > l
|
yyb7 = yyj7 > l
|
||||||
} else {
|
} else {
|
||||||
yyb5 = r.CheckBreak()
|
yyb7 = r.CheckBreak()
|
||||||
}
|
}
|
||||||
if yyb5 {
|
if yyb7 {
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -44149,21 +44221,43 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder
|
|||||||
if r.TryDecodeAsNil() {
|
if r.TryDecodeAsNil() {
|
||||||
x.Hard = nil
|
x.Hard = nil
|
||||||
} else {
|
} else {
|
||||||
yyv6 := &x.Hard
|
yyv8 := &x.Hard
|
||||||
yyv6.CodecDecodeSelf(d)
|
yyv8.CodecDecodeSelf(d)
|
||||||
|
}
|
||||||
|
yyj7++
|
||||||
|
if yyhl7 {
|
||||||
|
yyb7 = yyj7 > l
|
||||||
|
} else {
|
||||||
|
yyb7 = r.CheckBreak()
|
||||||
|
}
|
||||||
|
if yyb7 {
|
||||||
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
x.Scopes = nil
|
||||||
|
} else {
|
||||||
|
yyv9 := &x.Scopes
|
||||||
|
yym10 := z.DecBinary()
|
||||||
|
_ = yym10
|
||||||
|
if false {
|
||||||
|
} else {
|
||||||
|
h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv9), d)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
for {
|
for {
|
||||||
yyj5++
|
yyj7++
|
||||||
if yyhl5 {
|
if yyhl7 {
|
||||||
yyb5 = yyj5 > l
|
yyb7 = yyj7 > l
|
||||||
} else {
|
} else {
|
||||||
yyb5 = r.CheckBreak()
|
yyb7 = r.CheckBreak()
|
||||||
}
|
}
|
||||||
if yyb5 {
|
if yyb7 {
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
z.DecSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
z.DecStructFieldNotFound(yyj5-1, "")
|
z.DecStructFieldNotFound(yyj7-1, "")
|
||||||
}
|
}
|
||||||
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
z.DecSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
}
|
}
|
||||||
@ -53826,6 +53920,116 @@ func (x codecSelfer1234) decSliceLimitRange(v *[]LimitRange, d *codec1978.Decode
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (x codecSelfer1234) encSliceResourceQuotaScope(v []ResourceQuotaScope, e *codec1978.Encoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
r.EncodeArrayStart(len(v))
|
||||||
|
for _, yyv1 := range v {
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayElem1234)
|
||||||
|
yyv1.CodecEncodeSelf(e)
|
||||||
|
}
|
||||||
|
z.EncSendContainerState(codecSelfer_containerArrayEnd1234)
|
||||||
|
}
|
||||||
|
|
||||||
|
func (x codecSelfer1234) decSliceResourceQuotaScope(v *[]ResourceQuotaScope, d *codec1978.Decoder) {
|
||||||
|
var h codecSelfer1234
|
||||||
|
z, r := codec1978.GenHelperDecoder(d)
|
||||||
|
_, _, _ = h, z, r
|
||||||
|
|
||||||
|
yyv1 := *v
|
||||||
|
yyh1, yyl1 := z.DecSliceHelperStart()
|
||||||
|
var yyc1 bool
|
||||||
|
_ = yyc1
|
||||||
|
if yyl1 == 0 {
|
||||||
|
if yyv1 == nil {
|
||||||
|
yyv1 = []ResourceQuotaScope{}
|
||||||
|
yyc1 = true
|
||||||
|
} else if len(yyv1) != 0 {
|
||||||
|
yyv1 = yyv1[:0]
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
} else if yyl1 > 0 {
|
||||||
|
var yyrr1, yyrl1 int
|
||||||
|
var yyrt1 bool
|
||||||
|
_, _ = yyrl1, yyrt1
|
||||||
|
yyrr1 = yyl1 // len(yyv1)
|
||||||
|
if yyl1 > cap(yyv1) {
|
||||||
|
|
||||||
|
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16)
|
||||||
|
if yyrt1 {
|
||||||
|
if yyrl1 <= cap(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyrl1]
|
||||||
|
} else {
|
||||||
|
yyv1 = make([]ResourceQuotaScope, yyrl1)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
yyv1 = make([]ResourceQuotaScope, yyrl1)
|
||||||
|
}
|
||||||
|
yyc1 = true
|
||||||
|
yyrr1 = len(yyv1)
|
||||||
|
} else if yyl1 != len(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyl1]
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
yyj1 := 0
|
||||||
|
for ; yyj1 < yyrr1; yyj1++ {
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if yyrt1 {
|
||||||
|
for ; yyj1 < yyl1; yyj1++ {
|
||||||
|
yyv1 = append(yyv1, "")
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
yyj1 := 0
|
||||||
|
for ; !r.CheckBreak(); yyj1++ {
|
||||||
|
|
||||||
|
if yyj1 >= len(yyv1) {
|
||||||
|
yyv1 = append(yyv1, "") // var yyz1 ResourceQuotaScope
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
yyh1.ElemContainerState(yyj1)
|
||||||
|
if yyj1 < len(yyv1) {
|
||||||
|
if r.TryDecodeAsNil() {
|
||||||
|
yyv1[yyj1] = ""
|
||||||
|
} else {
|
||||||
|
yyv1[yyj1] = ResourceQuotaScope(r.DecodeString())
|
||||||
|
}
|
||||||
|
|
||||||
|
} else {
|
||||||
|
z.DecSwallow()
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
if yyj1 < len(yyv1) {
|
||||||
|
yyv1 = yyv1[:yyj1]
|
||||||
|
yyc1 = true
|
||||||
|
} else if yyj1 == 0 && yyv1 == nil {
|
||||||
|
yyv1 = []ResourceQuotaScope{}
|
||||||
|
yyc1 = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
yyh1.End()
|
||||||
|
if yyc1 {
|
||||||
|
*v = yyv1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.Encoder) {
|
func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.Encoder) {
|
||||||
var h codecSelfer1234
|
var h codecSelfer1234
|
||||||
z, r := codec1978.GenHelperEncoder(e)
|
z, r := codec1978.GenHelperEncoder(e)
|
||||||
@ -53865,7 +54069,7 @@ func (x codecSelfer1234) decSliceResourceQuota(v *[]ResourceQuota, d *codec1978.
|
|||||||
|
|
||||||
yyrg1 := len(yyv1) > 0
|
yyrg1 := len(yyv1) > 0
|
||||||
yyv21 := yyv1
|
yyv21 := yyv1
|
||||||
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 216)
|
yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 240)
|
||||||
if yyrt1 {
|
if yyrt1 {
|
||||||
if yyrl1 <= cap(yyv1) {
|
if yyrl1 <= cap(yyv1) {
|
||||||
yyv1 = yyv1[:yyrl1]
|
yyv1 = yyv1[:yyrl1]
|
||||||
|
@ -1351,8 +1351,9 @@ func (ResourceQuotaList) SwaggerDoc() map[string]string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
var map_ResourceQuotaSpec = map[string]string{
|
var map_ResourceQuotaSpec = map[string]string{
|
||||||
"": "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.",
|
"": "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.",
|
||||||
"hard": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota",
|
"hard": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota",
|
||||||
|
"scopes": "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.",
|
||||||
}
|
}
|
||||||
|
|
||||||
func (ResourceQuotaSpec) SwaggerDoc() map[string]string {
|
func (ResourceQuotaSpec) SwaggerDoc() map[string]string {
|
||||||
|
Loading…
Reference in New Issue
Block a user